mem-cred: Fix memory leak when replacing existing CRLs
authorTobias Brunner <tobias@strongswan.org>
Mon, 2 May 2016 14:04:43 +0000 (16:04 +0200)
committerTobias Brunner <tobias@strongswan.org>
Wed, 11 May 2016 10:16:36 +0000 (12:16 +0200)
Fixes #1442.

src/libstrongswan/credentials/sets/mem_cred.c

index 4884c4b..988e709 100644 (file)
@@ -250,6 +250,7 @@ METHOD(mem_cred_t, add_crl, bool,
                                if (new)
                                {
                                        this->untrusted->remove_at(this->untrusted, enumerator);
+                                       current->destroy(current);
                                }
                                else
                                {