Commit dad22268 by Basile Starynkevitch Committed by Basile Starynkevitch

gengtype.c (parse_program_options): Added allocation of plugin_files, and…

gengtype.c (parse_program_options): Added allocation of plugin_files, and corrected test on nb_plugin_files.


2010-10-18  Basile Starynkevitch  <basile@starynkevitch.net>

	* gengtype.c (parse_program_options): Added allocation of
	plugin_files, and corrected test on nb_plugin_files.

From-SVN: r165608
parent 187d3518
2010-10-18 Basile Starynkevitch <basile@starynkevitch.net>
* gengtype.c (parse_program_options): Added allocation of
plugin_files, and corrected test on nb_plugin_files.
2010-10-17 Nicola Pero <nicola.pero@meta-innovation.com> 2010-10-17 Nicola Pero <nicola.pero@meta-innovation.com>
Merge from 'apple/trunk' branch on FSF servers. Merge from 'apple/trunk' branch on FSF servers.
...@@ -4395,6 +4395,7 @@ parse_program_options (int argc, char **argv) ...@@ -4395,6 +4395,7 @@ parse_program_options (int argc, char **argv)
if (optind >= argc) if (optind >= argc)
fatal ("no source files given in plugin mode"); fatal ("no source files given in plugin mode");
nb_plugin_files = argc - optind; nb_plugin_files = argc - optind;
plugin_files = XNEWVEC (char*, nb_plugin_files);
for (i = 0; i < (int) nb_plugin_files; i++) for (i = 0; i < (int) nb_plugin_files; i++)
{ {
char *name = argv[i + optind]; char *name = argv[i + optind];
...@@ -4488,7 +4489,7 @@ main (int argc, char **argv) ...@@ -4488,7 +4489,7 @@ main (int argc, char **argv)
fatal ("No read state given in plugin mode for %s", fatal ("No read state given in plugin mode for %s",
plugin_output_filename); plugin_output_filename);
if (nb_plugin_files <= 0 || !plugin_files) if (nb_plugin_files == 0 || !plugin_files)
fatal ("No plugin files given in plugin mode for %s", fatal ("No plugin files given in plugin mode for %s",
plugin_output_filename); plugin_output_filename);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment