aboutsummaryrefslogtreecommitdiff
path: root/src/core
diff options
context:
space:
mode:
authorDavid Barksdale <amatus@amat.us>2017-10-09 21:42:12 -0500
committerDavid Barksdale <amatus@amat.us>2017-10-09 21:42:12 -0500
commit45140f0fd3426e9689c6d1e5e758f1b75c450e90 (patch)
treebe4ba1999e6e04a92e94f33b6bb9e285925ac77a /src/core
parent2a48c70fa17df09d1315c37426c3c48f6414f701 (diff)
downloadgnunet-45140f0fd3426e9689c6d1e5e758f1b75c450e90.tar.gz
gnunet-45140f0fd3426e9689c6d1e5e758f1b75c450e90.zip
Fix memory leak in test_core_api_reliability
Diffstat (limited to 'src/core')
-rw-r--r--src/core/test_core_api_reliability.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/src/core/test_core_api_reliability.c b/src/core/test_core_api_reliability.c
index 900c9f732..528093c99 100644
--- a/src/core/test_core_api_reliability.c
+++ b/src/core/test_core_api_reliability.c
@@ -381,6 +381,7 @@ process_hello (void *cls,
381 GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, 381 GNUNET_log (GNUNET_ERROR_TYPE_DEBUG,
382 "Received (my) `%s' from transport service\n", "HELLO"); 382 "Received (my) `%s' from transport service\n", "HELLO");
383 GNUNET_assert (message != NULL); 383 GNUNET_assert (message != NULL);
384 GNUNET_free_non_null (p->hello);
384 p->hello = GNUNET_copy_message (message); 385 p->hello = GNUNET_copy_message (message);
385 if ((p == &p1) && (NULL == p2.oh)) 386 if ((p == &p1) && (NULL == p2.oh))
386 p2.oh = GNUNET_TRANSPORT_offer_hello (p2.cfg, 387 p2.oh = GNUNET_TRANSPORT_offer_hello (p2.cfg,
@@ -518,6 +519,8 @@ main (int argc,
518 &ok); 519 &ok);
519 stop_arm (&p1); 520 stop_arm (&p1);
520 stop_arm (&p2); 521 stop_arm (&p2);
522 GNUNET_free_non_null (p1.hello);
523 GNUNET_free_non_null (p2.hello);
521 GNUNET_DISK_directory_remove ("/tmp/test-gnunet-core-peer-1"); 524 GNUNET_DISK_directory_remove ("/tmp/test-gnunet-core-peer-1");
522 GNUNET_DISK_directory_remove ("/tmp/test-gnunet-core-peer-2"); 525 GNUNET_DISK_directory_remove ("/tmp/test-gnunet-core-peer-2");
523 526