From: Vsevolod Stakhov Date: Thu, 14 Jul 2011 14:01:09 +0000 (+0400) Subject: Fix core dumps when no symbols are found in a message. X-Git-Tag: 0.4.0~20 X-Git-Url: https://source.dussan.org/?a=commitdiff_plain;h=1d14cf8fc1a73060c18e71bf65ecb6f20823dd9e;p=rspamd.git Fix core dumps when no symbols are found in a message. --- diff --git a/src/protocol.c b/src/protocol.c index 3eae408de..efce45f7a 100644 --- a/src/protocol.c +++ b/src/protocol.c @@ -1088,7 +1088,7 @@ show_metric_result (gpointer metric_name, gpointer metric_value, void *user_data m = g_hash_table_lookup (task->cfg->metrics, DEFAULT_METRIC); default_required_score = m->required_score; default_score = 0; - if (!check_metric_settings (metric_res, &ms, &rs)) { + if (metric_res != NULL && !check_metric_settings (metric_res, &ms, &rs)) { ms = m->required_score; rs = m->reject_score; }