does not terminate on invalid uri
[oweals/gnunet.git] / src / mesh / mesh_test_lib.c
index 760e74c9f026e82c40f831efd2a2c179dd5613dd..cec74f2b51697e384ef552aa9a47c2ada65c831f 100644 (file)
@@ -24,7 +24,6 @@
  */
 #include "platform.h"
 #include "gnunet_util_lib.h"
-#include "gnunet_testing_lib.h"
 #include "mesh_test_lib.h"
 #include "gnunet_mesh_service.h"
 
@@ -202,7 +201,11 @@ GNUNET_MESH_TEST_cleanup (struct GNUNET_MESH_TEST_Context *ctx)
   unsigned int i;
 
   for (i = 0; i < ctx->num_peers; i++)
+  {
+    GNUNET_assert (NULL != ctx->ops[i]);
     GNUNET_TESTBED_operation_done (ctx->ops[i]);
+    ctx->ops[i] = NULL;
+  }
   GNUNET_free (ctx->ops);
   GNUNET_free (ctx->meshes);
   GNUNET_free (ctx);
@@ -273,7 +276,7 @@ GNUNET_MESH_TEST_run (const char *testname,
                       const GNUNET_MESH_ApplicationType* stypes)
 {
   struct GNUNET_MESH_TEST_Context *ctx;
-  
+
   ctx = GNUNET_malloc (sizeof (struct GNUNET_MESH_TEST_Context));
   ctx->num_peers = num_peers;
   ctx->ops = GNUNET_malloc (num_peers * sizeof (struct GNUNET_TESTBED_Operation *));