From: sayle Date: Sun, 29 Feb 2004 14:09:58 +0000 (+0000) Subject: * jcf-parse.c (java_parse_file): Handle the case that input_filename X-Git-Tag: upstream/4.9.2~72663 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=905df476aa8b9760743f8759e8d25dc6212eb056;p=platform%2Fupstream%2Flinaro-gcc.git * jcf-parse.c (java_parse_file): Handle the case that input_filename is NULL. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@78649 138bc75d-0d04-0410-961f-82ee72b054a4 --- diff --git a/gcc/java/ChangeLog b/gcc/java/ChangeLog index 1c5aded..8b46231 100644 --- a/gcc/java/ChangeLog +++ b/gcc/java/ChangeLog @@ -1,3 +1,8 @@ +2004-02-29 Roger Sayle + + * jcf-parse.c (java_parse_file): Handle the case that input_filename + is NULL. + 2004-02-27 Per Bothner * parse.y (build_assertion): Re-do 02-25 change following Jeff Sturm diff --git a/gcc/java/jcf-parse.c b/gcc/java/jcf-parse.c index 309c28d..e8fd413 100644 --- a/gcc/java/jcf-parse.c +++ b/gcc/java/jcf-parse.c @@ -910,9 +910,9 @@ java_parse_file (int set_yydebug ATTRIBUTE_UNUSED) finput = NULL; } else - list = xstrdup (input_filename); + list = input_filename ? xstrdup (input_filename) : 0; - do + while (list) { for (next = list; ; ) { @@ -991,7 +991,6 @@ java_parse_file (int set_yydebug ATTRIBUTE_UNUSED) } list = next; } - while (next); if (filename_count == 0) warning ("no input file specified");