From 6035da499e4311aefda6f1c6ba1acef9cf3ded7e Mon Sep 17 00:00:00 2001 From: Christian Grothoff Date: Mon, 29 Oct 2012 16:40:46 +0000 Subject: [PATCH] -fixes --- src/testbed/gnunet-helper-testbed.c | 6 +++++- src/testbed/test_testbed_api_3peers_3controllers.c | 1 + src/testbed/test_testbed_api_controllerlink.c | 1 + src/testbed/testbed_api.c | 5 ++++- src/testbed/testbed_api_hosts.c | 1 + 5 files changed, 12 insertions(+), 2 deletions(-) diff --git a/src/testbed/gnunet-helper-testbed.c b/src/testbed/gnunet-helper-testbed.c index 0e70645c7..0f9a76699 100644 --- a/src/testbed/gnunet-helper-testbed.c +++ b/src/testbed/gnunet-helper-testbed.c @@ -225,6 +225,7 @@ tokenizer_cb (void *cls, void *client, struct GNUNET_TESTBED_HelperReply *reply; struct GNUNET_CONFIGURATION_Handle *cfg; struct WriteContext *wc; + char *binary; char *controller; char *hostname; char *config; @@ -312,11 +313,14 @@ tokenizer_cb (void *cls, void *client, goto error; } LOG_DEBUG ("Staring testbed with config: %s\n", config); + binary = GNUNET_OS_get_libexec_binary_path ("gnunet-service-testbed"); testbed = GNUNET_OS_start_process (GNUNET_YES, GNUNET_OS_INHERIT_STD_ERR /*verbose? */ , NULL, - NULL, "gnunet-service-testbed", + NULL, + binary, "gnunet-service-testbed", "-c", config, NULL); + GNUNET_free (binary); GNUNET_free (config); if (NULL == testbed) { diff --git a/src/testbed/test_testbed_api_3peers_3controllers.c b/src/testbed/test_testbed_api_3peers_3controllers.c index 691e04727..206944ae8 100644 --- a/src/testbed/test_testbed_api_3peers_3controllers.c +++ b/src/testbed/test_testbed_api_3peers_3controllers.c @@ -707,6 +707,7 @@ check_ssh (char *host_str) "-o", "NoHostAuthenticationForLocalhost=yes", "-q", host_str, "which", "gnunet-helper-testbed", NULL }; + // FIXME: the above no longer works with libexec/-installation! struct GNUNET_OS_Process *auxp; enum GNUNET_OS_ProcessStatusType type; unsigned long code; diff --git a/src/testbed/test_testbed_api_controllerlink.c b/src/testbed/test_testbed_api_controllerlink.c index 703815a2d..abde65166 100644 --- a/src/testbed/test_testbed_api_controllerlink.c +++ b/src/testbed/test_testbed_api_controllerlink.c @@ -660,6 +660,7 @@ check_ssh (char *host_str) "-o", "NoHostAuthenticationForLocalhost=yes", "-q", host_str, "which", "gnunet-helper-testbed", NULL }; + // FIXME: the above no longer works with libexec/-installation! struct GNUNET_OS_Process *auxp; enum GNUNET_OS_ProcessStatusType type; unsigned long code; diff --git a/src/testbed/testbed_api.c b/src/testbed/testbed_api.c index c55e7373a..9696785f3 100644 --- a/src/testbed/testbed_api.c +++ b/src/testbed/testbed_api.c @@ -1453,13 +1453,15 @@ GNUNET_TESTBED_controller_start (const char *controller_ip, static char *const binary_argv[] = { HELPER_TESTBED_BINARY, NULL }; - + hostname = NULL; cp = GNUNET_malloc (sizeof (struct GNUNET_TESTBED_ControllerProc)); if ((NULL == host) || (0 == GNUNET_TESTBED_host_get_id_ (host))) + { cp->helper = GNUNET_HELPER_start (GNUNET_YES, HELPER_TESTBED_BINARY, binary_argv, &helper_mst, &helper_exp_cb, cp); + } else { char *remote_args[10]; @@ -1483,6 +1485,7 @@ GNUNET_TESTBED_controller_start (const char *controller_ip, remote_args[argp++] = "-o"; remote_args[argp++] = "NoHostAuthenticationForLocalhost=yes"; remote_args[argp++] = cp->dst; + // FIXME: lib/gnunet/libexec/-prefix missing here!!! remote_args[argp++] = HELPER_TESTBED_BINARY_SSH; remote_args[argp++] = NULL; GNUNET_assert (argp == 10); diff --git a/src/testbed/testbed_api_hosts.c b/src/testbed/testbed_api_hosts.c index 1663f8962..387da99e0 100644 --- a/src/testbed/testbed_api_hosts.c +++ b/src/testbed/testbed_api_hosts.c @@ -518,6 +518,7 @@ GNUNET_TESTBED_is_host_habitable (const struct GNUNET_TESTBED_Host *host) remote_args[argp++] = "-o"; remote_args[argp++] = "NoHostAuthenticationForLocalhost=yes"; remote_args[argp++] = ssh_addr; + // FIXME: this no longer works with 'libexec/' paths! remote_args[argp++] = "which"; remote_args[argp++] = "gnunet-helper-testbed"; remote_args[argp++] = NULL; -- 2.25.1