diff options
author | Vsevolod Stakhov <vsevolod@highsecure.ru> | 2015-05-19 15:37:02 +0100 |
---|---|---|
committer | Vsevolod Stakhov <vsevolod@highsecure.ru> | 2015-05-19 16:29:21 +0100 |
commit | 0583ca87da55b9d83d9cbd8b3c42ff0237f8d457 (patch) | |
tree | 16dab11bba3ae9f65eb6472623639821ee581f47 /src/libutil/radix.c | |
parent | b1529dd39bf66af5ad3cd1ea9b8c500443800a20 (diff) | |
download | rspamd-0583ca87da55b9d83d9cbd8b3c42ff0237f8d457.tar.gz rspamd-0583ca87da55b9d83d9cbd8b3c42ff0237f8d457.zip |
Do not try dereference NULL pointer.
Diffstat (limited to 'src/libutil/radix.c')
-rw-r--r-- | src/libutil/radix.c | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/src/libutil/radix.c b/src/libutil/radix.c index 3ca4c8716..39fc39445 100644 --- a/src/libutil/radix.c +++ b/src/libutil/radix.c @@ -537,8 +537,10 @@ radix_create_compressed (void) void radix_destroy_compressed (radix_compressed_t *tree) { - rspamd_mempool_delete (tree->pool); - g_slice_free1 (sizeof (*tree), tree); + if (tree) { + rspamd_mempool_delete (tree->pool); + g_slice_free1 (sizeof (*tree), tree); + } } uintptr_t |