fixing valgrind unconditional jump error
authorSree Harsha Totakura <totakura@in.tum.de>
Tue, 18 Sep 2012 15:34:01 +0000 (15:34 +0000)
committerSree Harsha Totakura <totakura@in.tum.de>
Tue, 18 Sep 2012 15:34:01 +0000 (15:34 +0000)
src/testbed/testbed_api.c

index 7808d7a34e5b64713ca4e87a6d6d32733bb97a6d..f12c0cf4aa0a01d7c82f2def7da22a6de70b4198 100644 (file)
@@ -1169,18 +1169,15 @@ GNUNET_TESTBED_controller_start (const char *controller_ip,
 {
   struct GNUNET_TESTBED_ControllerProc *cp;
   struct GNUNET_TESTBED_HelperInit *msg;
-
+  static char *const binary_argv[] = {
+    HELPER_TESTBED_BINARY, NULL
+  };
+  
   cp = GNUNET_malloc (sizeof (struct GNUNET_TESTBED_ControllerProc));
   if ((NULL == host) || (0 == GNUNET_TESTBED_host_get_id_ (host)))
-  {
-    char *const binary_argv[] = {
-      HELPER_TESTBED_BINARY, NULL
-    };
-
     cp->helper =
         GNUNET_HELPER_start (GNUNET_YES, HELPER_TESTBED_BINARY, binary_argv,
                              &helper_mst, &helper_exp_cb, cp);
-  }
   else
   {
     char *remote_args[8];