diff options
-rw-r--r-- | gram.y | 13 |
1 files changed, 8 insertions, 5 deletions
@@ -210,19 +210,22 @@ main (int argc, char **argv) case 'f': if (!cw_list) read_include (&cw_list, cwfile); file_list = NULL; read_include (&file_list, optarg); - for (s = file_list->head; s; s = s->next) + if (file_list) { - openaliases_prefix (optarg, s->str); - yyparse (); - file_count++; + for (s = file_list->head; s; s = s->next) + { + openaliases_prefix (optarg, s->str); + yyparse (); + file_count++; + } + slist_destroy (&file_list); } - slist_destroy (&file_list); break; case 'h': usage (); exit (0); |