OSDN Git Service

* tradcpp.c (main): Rename 'perror' label to 'sys_error'.
authorzack <zack@138bc75d-0d04-0410-961f-82ee72b054a4>
Thu, 13 Jul 2000 03:06:25 +0000 (03:06 +0000)
committerzack <zack@138bc75d-0d04-0410-961f-82ee72b054a4>
Thu, 13 Jul 2000 03:06:25 +0000 (03:06 +0000)
git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@35004 138bc75d-0d04-0410-961f-82ee72b054a4

gcc/ChangeLog
gcc/tradcpp.c

index 44811cc..ad325ba 100644 (file)
@@ -1,5 +1,7 @@
 2000-07-12  Zack Weinberg  <zack@wolery.cumb.org>
 
+       * tradcpp.c (main): Rename 'perror' label to 'sys_error'.
+
        * cppexp.c, cpphash.c, cpphash.h, cppinit.c, cpplex.c,
        cpplib.c, cpplib.h: Eradicate all traces of code dependent on
        traditional, lang_chill, or lang_fortran.
index 1936579..2afb550 100644 (file)
@@ -793,7 +793,7 @@ main (argc, argv)
     in_fname = "";
     f = 0;
   } else if ((f = open (in_fname, O_RDONLY, 0666)) < 0)
-    goto perror;
+    goto sys_error;
 
   /* Either of two environment variables can specify output of deps.
      Its value is either "OUTPUT_FILE" or "OUTPUT_FILE DEPS_TARGET",
@@ -882,7 +882,7 @@ main (argc, argv)
   }
 
   if (file_size_and_mode (f, &st_mode, &st_size))
-    goto perror;
+    goto sys_error;
   fp->fname = in_fname;
   fp->lineno = 1;
   /* JF all this is mine about reading pipes and ttys */
@@ -901,11 +901,11 @@ main (argc, argv)
     bufp = fp->buf;
     for (;;) {
       cnt = read (f, bufp, bsize - size);
-      if (cnt < 0) goto perror;        /* error! */
-      if (cnt == 0) break;     /* End of file */
+      if (cnt < 0) goto sys_error;     /* error! */
+      if (cnt == 0) break;             /* End of file */
       size += cnt;
       bufp += cnt;
-      if (bsize == size) {     /* Buffer is full! */
+      if (bsize == size) {             /* Buffer is full! */
         bsize *= 2;
         fp->buf = (U_CHAR *) xrealloc (fp->buf, bsize + 2);
        bufp = fp->buf + size;  /* May have moved */
@@ -923,7 +923,7 @@ main (argc, argv)
       i = read (f, fp->buf + fp->length, st_size);
       if (i <= 0) {
         if (i == 0) break;
-       goto perror;
+       goto sys_error;
       }
       fp->length += i;
       st_size -= i;
@@ -979,7 +979,7 @@ main (argc, argv)
     exit (FATAL_EXIT_CODE);
   exit (SUCCESS_EXIT_CODE);
 
perror:
sys_error:
   pfatal_with_name (in_fname);
 }