From 0a0036407218d7f9588d2b6b796b2a6f779bf700 Mon Sep 17 00:00:00 2001 From: Sree Harsha Totakura Date: Tue, 30 Oct 2012 23:03:07 +0000 Subject: for starting up non gnunet helpers (SSH for example) --- src/util/helper.c | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) (limited to 'src/util/helper.c') diff --git a/src/util/helper.c b/src/util/helper.c index c0681c804..372f8407e 100644 --- a/src/util/helper.c +++ b/src/util/helper.c @@ -410,12 +410,16 @@ GNUNET_HELPER_start (int with_control_pipe, GNUNET_HELPER_ExceptionCallback exp_cb, void *cb_cls) { - struct GNUNET_HELPER_Handle*h; + struct GNUNET_HELPER_Handle *h; unsigned int c; h = GNUNET_malloc (sizeof (struct GNUNET_HELPER_Handle)); h->with_control_pipe = with_control_pipe; - h->binary_name = GNUNET_OS_get_libexec_binary_path (binary_name); + /* Lookup in libexec path only if we are starting gnunet helpers */ + if (NULL != strstr (binary_name, "gnunet")) + h->binary_name = GNUNET_OS_get_libexec_binary_path (binary_name); + else + h->binary_name = strdup (binary_name); for (c = 0; NULL != binary_argv[c]; c++) c++; h->binary_argv = GNUNET_malloc (sizeof (char *) * (c + 1)); -- cgit v1.2.3