X-Git-Url: https://git.librecmc.org/?a=blobdiff_plain;f=src%2Ftestbed%2Ftest_gnunet_helper_testbed.c;h=cf4559c263cc202e3b8ae02e09ed7e2095014bc7;hb=a900b29ddaa9ea46c731b054b5e3ef3e725b95a8;hp=db889c1ec7967f264a7f59efa75832115c5edd67;hpb=87566df009e48391b08d3f1cdf3dedf7debcac7b;p=oweals%2Fgnunet.git diff --git a/src/testbed/test_gnunet_helper_testbed.c b/src/testbed/test_gnunet_helper_testbed.c index db889c1ec..cf4559c26 100644 --- a/src/testbed/test_gnunet_helper_testbed.c +++ b/src/testbed/test_gnunet_helper_testbed.c @@ -1,6 +1,6 @@ /* This file is part of GNUnet - (C) 2012 Christian Grothoff (and other contributing authors) + (C) 2008--2013 Christian Grothoff (and other contributing authors) GNUnet is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published @@ -87,7 +87,8 @@ do_shutdown (void *cls, const struct GNUNET_SCHEDULER_TaskContext *tc) { if (GNUNET_SCHEDULER_NO_TASK != abort_task) GNUNET_SCHEDULER_cancel (abort_task); - GNUNET_HELPER_stop (helper); + if (NULL != helper) + GNUNET_HELPER_stop (helper, GNUNET_NO); GNUNET_free_non_null (msg); if (NULL != cfg) GNUNET_CONFIGURATION_destroy (cfg); @@ -205,14 +206,14 @@ run (void *cls, char *const *args, const char *cfgfile, "gnunet-helper-testbed", NULL }; - const char *controller_name = "127.0.0.1"; + const char *trusted_ip = "127.0.0.1"; helper = GNUNET_HELPER_start (GNUNET_YES, "gnunet-helper-testbed", binary_argv, &mst_cb, &exp_cb, NULL); GNUNET_assert (NULL != helper); cfg = GNUNET_CONFIGURATION_dup (cfg2); - msg = GNUNET_TESTBED_create_helper_init_msg_ (controller_name, NULL, cfg); + msg = GNUNET_TESTBED_create_helper_init_msg_ (trusted_ip, NULL, cfg); shandle = GNUNET_HELPER_send (helper, &msg->header, GNUNET_NO, &cont_cb, NULL); GNUNET_assert (NULL != shandle);