#include "tags.h"
#include "log.h"
-#define PREFSBUFSIZE 1024
-
GSList * pre_global_processing = NULL;
GSList * post_global_processing = NULL;
GSList * filtering_rules = NULL;
for (tmp = prop->action_list ; tmp != NULL ; tmp = tmp->next) {
filteringaction_free(tmp->data);
}
+ g_slist_free(prop->action_list);
g_free(prop->name);
g_free(prop);
}
gint errors = 0;
if (!addressbook_peek_folder_exists(action->destination, &book, &folder)) {
- g_warning("addressbook folder not found '%s'\n", action->destination);
+ g_warning("addressbook folder not found '%s'\n", action->destination?action->destination:"(null)");
return FALSE;
}
if (!book) {
g_slist_free(address_list);
end_address_completion();
} else {
- g_warning("header '%s' not set or empty\n", action->header);
+ g_warning("header '%s' not set or empty\n", action->header?action->header:"(null)");
}
return (errors == 0);
}
log_status_ok(LOG_DEBUG_FILTERING,
_("rule is account-based [id=%d, name='%s'], "
"matching the account currently used to retrieve messages\n"),
- ac_prefs->account_id, ac_prefs->account_name);
+ ac_prefs->account_id, ac_prefs?ac_prefs->account_name:_("NON_EXISTENT"));
}
}
}
log_status_skip(LOG_DEBUG_FILTERING,
_("rule is account-based [id=%d, name='%s'], "
"not matching the account currently used to retrieve messages [id=%d, name='%s']\n"),
- filtering->account_id, account->account_name,
- ac_prefs->account_id, ac_prefs->account_name);
+ filtering->account_id, account?account->account_name:_("NON_EXISTENT"),
+ ac_prefs->account_id, ac_prefs?ac_prefs->account_name:_("NON_EXISTENT"));
}
}
}
log_status_ok(LOG_DEBUG_FILTERING,
_("rule is account-based [id=%d, name='%s'], "
"but all rules are applied on user request\n"),
- filtering->account_id, account->account_name);
+ filtering->account_id, account?account->account_name:_("NON_EXISTENT"));
}
}
}
log_status_skip(LOG_DEBUG_FILTERING,
_("rule is account-based [id=%d, name='%s'], "
"skipped on user request\n"),
- filtering->account_id, account->account_name);
+ filtering->account_id, account?account->account_name:_("NON_EXISTENT"));
} else {
log_status_skip(LOG_DEBUG_FILTERING,
_("rule is account-based, "
log_status_skip(LOG_DEBUG_FILTERING,
_("rule is account-based [id=%d, name='%s'], "
"not matching current account [id=%d, name='%s']\n"),
- filtering->account_id, account->account_name,
- cur_account->account_id, cur_account->account_name);
+ filtering->account_id, account?account->account_name:_("NON_EXISTENT"),
+ cur_account->account_id, cur_account?cur_account->account_name:_("NON_EXISTENT"));
} else {
log_status_skip(LOG_DEBUG_FILTERING,
_("rule is account-based, "
log_status_ok(LOG_DEBUG_FILTERING,
_("rule is account-based [id=%d, name='%s'], "
"current account [id=%d, name='%s']\n"),
- account->account_id, account->account_name,
- cur_account->account_id, cur_account->account_name);
+ account->account_id, account?account->account_name:_("NON_EXISTENT"),
+ cur_account->account_id, cur_account?cur_account->account_name:_("NON_EXISTENT"));
}
}
}
_("processing rule <unnamed> [ %s ]\n"),
buf);
}
+ g_free(buf);
}
if (filtering_match_condition(filtering, info, ac_prefs)) {
if (prefs_common.enable_filtering_debug) {
gchar *tmp = _("undetermined");
-
+#ifndef G_OS_WIN32
switch (context) {
case FILTERING_INCORPORATION:
tmp = _("incorporation");
debug_filtering_session = FALSE;
break;
}
+#else
+ debug_filtering_session = FALSE;
+#endif
if (debug_filtering_session) {
gchar *file = procmsg_get_message_file_path(info);
gchar *spc = g_strnfill(LOG_TIME_LEN + 1, ' ');