]> source.dussan.org Git - rspamd.git/commitdiff
[Fix] Do not crash when resolver failed to initialize
authorVsevolod Stakhov <vsevolod@highsecure.ru>
Tue, 13 Jun 2017 20:12:02 +0000 (21:12 +0100)
committerVsevolod Stakhov <vsevolod@highsecure.ru>
Tue, 13 Jun 2017 20:12:02 +0000 (21:12 +0100)
contrib/librdns/resolver.c

index d6ddea5769860e9edf62555f53a1f2aaa2ccbdba..ca93d78728933535416ceff4cdd38383638e0959 100644 (file)
@@ -530,7 +530,7 @@ rdns_make_request_full (
        const char *cur_name, *last_name = NULL;
        struct rdns_compression_entry *comp = NULL;
 
-       if (!resolver->initialized) {
+       if (resolver == NULL || !resolver->initialized) {
                return NULL;
        }