From 67cca0b45f37a7c948c5635d5f33c5da91b003d8 Mon Sep 17 00:00:00 2001 From: Matthias Wachs Date: Thu, 19 Jul 2012 12:50:32 +0000 Subject: [PATCH] memory leak --- src/ats/gnunet-service-ats_addresses.c | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) diff --git a/src/ats/gnunet-service-ats_addresses.c b/src/ats/gnunet-service-ats_addresses.c index 790c30e8c..72176fc76 100644 --- a/src/ats/gnunet-service-ats_addresses.c +++ b/src/ats/gnunet-service-ats_addresses.c @@ -344,18 +344,15 @@ lookup_address (const struct GNUNET_PeerIdentity *peer, /* Get existing address or address with session == 0 */ old = find_address (peer, aa); + free_address (aa); if (old == NULL) { - GNUNET_free (aa); return NULL; } else if (old->session_id != session_id) { - GNUNET_free (aa); - GNUNET_break (0); return NULL; } - return old; } -- 2.25.1