Do $-expansion for OPTIONS of simple services
authorFlorian Dold <florian.dold@gmail.com>
Mon, 29 Feb 2016 00:12:10 +0000 (00:12 +0000)
committerFlorian Dold <florian.dold@gmail.com>
Mon, 29 Feb 2016 00:12:10 +0000 (00:12 +0000)
In the future, this should also handle escaping
and quotation.  For compatibility reasons, the
expansion is only done for simple service configs.

src/arm/gnunet-service-arm.c

index 628bbc99b3e41cf2ff8bf6c86e4332a0f27d6823..0ffda9331e765fc60baa402d4befea136c85c6a7 100644 (file)
@@ -520,6 +520,10 @@ start_process (struct ServiceList *sl,
     GNUNET_log (GNUNET_ERROR_TYPE_DEBUG,
                 "Starting simple service `%s' using binary `%s'\n",
                 sl->name, sl->binary);
+    /* FIXME: dollar expansion should only be done outside
+     * of ''-quoted strings, escaping should be considered. */
+    if (NULL != options)
+      options = GNUNET_CONFIGURATION_expand_dollar (cfg, options);
     sl->proc =
       GNUNET_OS_start_process_s (sl->pipe_control,
                                  GNUNET_OS_INHERIT_STD_OUT_AND_ERR,