Commit b416fab4 by Roger Sayle Committed by Roger Sayle

parse.c (ffe_parse_file): Handle the case that main_input_filename is NULL.


	* parse.c (ffe_parse_file): Handle the case that main_input_filename
	is NULL.

From-SVN: r78650
parent 083474cc
2004-02-29 Roger Sayle <roger@eyesopen.com>
* parse.c (ffe_parse_file): Handle the case that main_input_filename
is NULL.
2004-02-24 Michael Matz <matz@suse.de> 2004-02-24 Michael Matz <matz@suse.de>
* Make-lang.in (sta.o-warn): Delete. * Make-lang.in (sta.o-warn): Delete.
......
...@@ -31,6 +31,7 @@ extern FILE *finput; ...@@ -31,6 +31,7 @@ extern FILE *finput;
void void
ffe_parse_file (int set_yydebug ATTRIBUTE_UNUSED) ffe_parse_file (int set_yydebug ATTRIBUTE_UNUSED)
{ {
const char *fname;
ffewhereFile wf; ffewhereFile wf;
if (ffe_is_version ()) if (ffe_is_version ())
...@@ -39,8 +40,9 @@ ffe_parse_file (int set_yydebug ATTRIBUTE_UNUSED) ...@@ -39,8 +40,9 @@ ffe_parse_file (int set_yydebug ATTRIBUTE_UNUSED)
if (!ffe_is_pedantic ()) if (!ffe_is_pedantic ())
ffe_set_is_pedantic (pedantic); ffe_set_is_pedantic (pedantic);
wf = ffewhere_file_new (main_input_filename, strlen (main_input_filename)); fname = main_input_filename ? main_input_filename : "<stdin>";
ffecom_file (main_input_filename); wf = ffewhere_file_new (fname, strlen (fname));
ffecom_file (fname);
ffe_file (wf, finput); ffe_file (wf, finput);
ffecom_finish_compile (); ffecom_finish_compile ();
......
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