commit 156aae9afd1c1f3a27155ef9d6cd3cde17233ee3 Author: Sebastian Gieltjes Date: Sun Mar 14 21:09:22 2010 +0100 Modified commandline string generation Every netlister is able to request the invoked commandline and now gets a valid string in return. Removed a debug output command. diff --git a/gnetlist/src/globals.c b/gnetlist/src/globals.c index 99d1b41..839ab72 100644 --- a/gnetlist/src/globals.c +++ b/gnetlist/src/globals.c @@ -64,7 +64,7 @@ GSList *pre_backend_list=NULL; GSList *post_backend_list=NULL; /* String holding command line */ -char *command_line; +char *command_line = NULL; /* Parameters passed to the backend from the command line */ GSList *backend_params = NULL; diff --git a/gnetlist/src/gnetlist.c b/gnetlist/src/gnetlist.c index 9b51b7b..faa63e4 100644 --- a/gnetlist/src/gnetlist.c +++ b/gnetlist/src/gnetlist.c @@ -122,6 +122,8 @@ void main_prog(void *closure, int argc, char *argv[]) argv_index = parse_commandline(argc, argv); cwd = g_get_current_dir(); + command_line = create_command_line(argc, argv); + /* this is a kludge to make sure that spice mode gets set */ /* Hacked by SDB to allow spice netlisters of arbitrary name * as long as they begin with "spice". For example, this spice @@ -130,10 +132,6 @@ void main_prog(void *closure, int argc, char *argv[]) if (guile_proc) { if (strncmp(guile_proc, "spice", 5) == 0) { netlist_mode = SPICE; - command_line = create_command_line(argc, argv); - - printf("Command line passed = %s \n", command_line); - } }