From e0bc3a68a2dcf7fca2ae0a56a1cc628556b354bd Mon Sep 17 00:00:00 2001 From: Olivier Roques Date: Wed, 8 Jan 2020 13:04:48 +0100 Subject: [CICN-27] Fix invalid pointer dealloc There is a deallocation of an invalid pointer in the destructor of an in-memory verifier object. This function is called by the destructor of consumer socket which fails because of that. The bug is visible only on Ubuntu 16.04. The bug was introduced in CICN-26 as an artifact of attempts to fix memory leaks in Android. There is no good reason to keep the changes causing the problem and the concerned lines can be safely removed. Signed-off-by: Olivier Roques Change-Id: Ibcde7dd7510d76f5aa91e5967a4261ec7eb49108 --- libparc/parc/security/parc_InMemoryVerifier.c | 2 -- 1 file changed, 2 deletions(-) diff --git a/libparc/parc/security/parc_InMemoryVerifier.c b/libparc/parc/security/parc_InMemoryVerifier.c index 00dddf46..b713abce 100644 --- a/libparc/parc/security/parc_InMemoryVerifier.c +++ b/libparc/parc/security/parc_InMemoryVerifier.c @@ -51,8 +51,6 @@ _parcInMemoryVerifier_Destructor(PARCInMemoryVerifier **verifierPtr) parcCryptoHasher_Release(&(verifier->hasher_sha256)); parcCryptoHasher_Release(&(verifier->hasher_sha512)); parcCryptoCache_Destroy(&(verifier->key_cache)); - parcMemory_Deallocate((void **)verifierPtr); - *verifierPtr = NULL; return true; } -- cgit 1.2.3-korg