From: Vsevolod Stakhov Date: Tue, 20 Jul 2010 13:41:42 +0000 (+0400) Subject: * Handle empty from header X-Git-Tag: 0.3.1~27 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=3fa94456e82ca03555173dc79091a4dc25947fd5;p=thirdparty%2Frspamd.git * Handle empty from header --- diff --git a/src/spf.c b/src/spf.c index 7a8de67462..ee8a4118f1 100644 --- a/src/spf.c +++ b/src/spf.c @@ -1087,7 +1087,7 @@ resolve_spf (struct worker_task *task, spf_cb_t callback) rec->task = task; rec->callback = callback; - if (task->from && (domain = strchr (task->from, '@'))) { + if (task->from && (domain = strchr (task->from, '@')) != NULL && *domain == '@') { rec->sender = task->from; rec->local_part = memory_pool_strdup (task->task_pool, task->from);