2
0
mirror of git://gcc.gnu.org/git/gcc.git synced 2025-04-18 05:50:27 +08:00

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
This commit is contained in:
Roger Sayle 2004-02-29 14:12:20 +00:00 committed by Roger Sayle
parent 083474cc69
commit b416fab459
2 changed files with 9 additions and 2 deletions

@ -1,3 +1,8 @@
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>
* Make-lang.in (sta.o-warn): Delete.

@ -31,6 +31,7 @@ extern FILE *finput;
void
ffe_parse_file (int set_yydebug ATTRIBUTE_UNUSED)
{
const char *fname;
ffewhereFile wf;
if (ffe_is_version ())
@ -39,8 +40,9 @@ ffe_parse_file (int set_yydebug ATTRIBUTE_UNUSED)
if (!ffe_is_pedantic ())
ffe_set_is_pedantic (pedantic);
wf = ffewhere_file_new (main_input_filename, strlen (main_input_filename));
ffecom_file (main_input_filename);
fname = main_input_filename ? main_input_filename : "<stdin>";
wf = ffewhere_file_new (fname, strlen (fname));
ffecom_file (fname);
ffe_file (wf, finput);
ffecom_finish_compile ();