]> git.saurik.com Git - bison.git/blobdiff - src/complain.c
* Makefile.maint: Sync with Autoconf:
[bison.git] / src / complain.c
index 1ad672ba599accbd5b7b03d570f54c299e027451..7d2f0c55646ec4571d77f89ef8f69c97a1f4e813 100644 (file)
@@ -29,8 +29,6 @@
 #if STDC_HEADERS || _LIBC
 # include <stdlib.h>
 # include <string.h>
 #if STDC_HEADERS || _LIBC
 # include <stdlib.h>
 # include <string.h>
-#else
-void exit ();
 #endif
 
 #include "complain.h"
 #endif
 
 #include "complain.h"
@@ -119,7 +117,7 @@ warn (const char *message, ...)
   va_list args;
 
   fflush (stdout);
   va_list args;
 
   fflush (stdout);
-  fprintf (stderr, "%s: %s", infile ? infile : program_name, _("warning: "));
+  fprintf (stderr, "%s: %s", current_file ? current_file : program_name, _("warning: "));
 
   va_start (args, message);
   vfprintf (stderr, message, args);
 
   va_start (args, message);
   vfprintf (stderr, message, args);
@@ -158,7 +156,7 @@ complain (const char *message, ...)
   va_list args;
 
   fflush (stdout);
   va_list args;
 
   fflush (stdout);
-  fprintf (stderr, "%s: ", infile ? infile : program_name);
+  fprintf (stderr, "%s: ", current_file ? current_file : program_name);
 
   va_start (args, message);
   vfprintf (stderr, message, args);
 
   va_start (args, message);
   vfprintf (stderr, message, args);
@@ -197,7 +195,7 @@ fatal (const char *message, ...)
   va_list args;
 
   fflush (stdout);
   va_list args;
 
   fflush (stdout);
-  fprintf (stderr, "%s: ", infile ? infile : program_name);
+  fprintf (stderr, "%s: ", current_file ? current_file : program_name);
 
   fputs (_("fatal error: "), stderr);
 
 
   fputs (_("fatal error: "), stderr);