From 133f27e620f19bb2d10714edb8a97ff01e4201d8 Mon Sep 17 00:00:00 2001 From: Vsevolod Stakhov Date: Tue, 14 Jun 2011 15:53:17 +0400 Subject: [PATCH] Add condition to fix inconsistent records in LRU cache. --- src/plugins/spf.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/plugins/spf.c b/src/plugins/spf.c index a7c48e702..1f6dcf071 100644 --- a/src/plugins/spf.c +++ b/src/plugins/spf.c @@ -218,7 +218,8 @@ static void spf_plugin_callback (struct spf_record *record, struct worker_task *task) { GList *l; - if (record) { + + if (record && record->addrs) { if ((l = rspamd_lru_hash_lookup (spf_module_ctx->spf_hash, record->sender_domain, task->tv.tv_sec)) == NULL) { l = spf_record_copy (record->addrs); -- 2.39.5