diff --git a/include/villas/config_helper.h b/include/villas/config_helper.h index af1be6658..14ce43145 100644 --- a/include/villas/config_helper.h +++ b/include/villas/config_helper.h @@ -43,7 +43,7 @@ int json_to_config(json_t *json, config_setting_t *parent); #endif /* LIBCONFIG_FOUND */ /* Create a JSON object from command line parameters. */ -json_t *json_load_cli(int argc, char *argv[]); +json_t *json_load_cli(int argc, const char *argv[]); int json_object_extend_str(json_t *orig, const char *str); diff --git a/lib/config_helper.c b/lib/config_helper.c index 9592da4bb..23b5590f7 100644 --- a/lib/config_helper.c +++ b/lib/config_helper.c @@ -248,12 +248,13 @@ success: json_object_set(subobj, key1, new); } -json_t * json_load_cli(int argc, char *argv[]) +json_t * json_load_cli(int argc, const char *argv[]) { - char *opt; - char *key = NULL; - char *value = NULL; - char *sep, *cpy; + const char *opt; + const char *key = NULL; + const char *value = NULL; + const char *sep; + char *cpy; json_t *json = json_object();