OSDN Git Service

(xstrdup): Renamed from strdup.
authorkenner <kenner@138bc75d-0d04-0410-961f-82ee72b054a4>
Tue, 14 Jun 1994 21:29:48 +0000 (21:29 +0000)
committerkenner <kenner@138bc75d-0d04-0410-961f-82ee72b054a4>
Tue, 14 Jun 1994 21:29:48 +0000 (21:29 +0000)
(check_protection): Call xstrdup, not strdup.

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@7457 138bc75d-0d04-0410-961f-82ee72b054a4

gcc/fix-header.c

index 81b46cf..d8c2527 100644 (file)
@@ -447,7 +447,7 @@ write_rbrac ()
 }
 
 char *
-strdup (str)
+xstrdup (str)
      char *str;
 {
   char *copy = (char *) xmalloc (strlen (str) + 1);
@@ -577,7 +577,7 @@ check_protection (ifndef_line, endif_line)
   c = inf_scan_ident (&buf, inf_skip_spaces (c));
   if (SSTRING_LENGTH (&buf) == 0 || c == EOF)
     return 0;
-  protect_name = strdup (buf.base);
+  protect_name = xstrdup (buf.base);
 
   INF_UNGET (c);
   c = inf_read_upto (&buf, '\n');