From bd2b737b0d3495d29d29c777f94cecbb2f632fcc Mon Sep 17 00:00:00 2001 From: Bart Polot Date: Fri, 24 Feb 2012 12:15:57 +0000 Subject: [PATCH] - Fix crashing testcases --- src/mesh/test_mesh_2dtorus.c | 2 +- src/mesh/test_mesh_local_2.c | 4 ++++ 2 files changed, 5 insertions(+), 1 deletion(-) diff --git a/src/mesh/test_mesh_2dtorus.c b/src/mesh/test_mesh_2dtorus.c index 6d91185cc..9946fe2d4 100644 --- a/src/mesh/test_mesh_2dtorus.c +++ b/src/mesh/test_mesh_2dtorus.c @@ -114,6 +114,7 @@ shutdown_callback (void *cls, const char *emsg) "test: All peers successfully shut down!\n"); } #endif + GNUNET_CONFIGURATION_destroy (testing_cfg); } @@ -125,7 +126,6 @@ shutdown_task (void *cls, const struct GNUNET_SCHEDULER_TaskContext *tc) #endif GNUNET_TESTING_daemons_stop (pg, TIMEOUT, &shutdown_callback, NULL); - GNUNET_CONFIGURATION_destroy (testing_cfg); } diff --git a/src/mesh/test_mesh_local_2.c b/src/mesh/test_mesh_local_2.c index c91548052..eff15046f 100644 --- a/src/mesh/test_mesh_local_2.c +++ b/src/mesh/test_mesh_local_2.c @@ -55,6 +55,10 @@ do_shutdown (void *cls, const struct GNUNET_SCHEDULER_TaskContext *tc) { GNUNET_SCHEDULER_cancel (abort_task); } + if (NULL != t) + { + GNUNET_MESH_tunnel_destroy(t); + } GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, "test: D1\n"); if (NULL != mesh_peer_1) { -- 2.25.1