Make it possible to alias stpcpy and strdup.
authorBruno Haible <bruno@clisp.org>
Wed, 11 Oct 2006 12:48:10 +0000 (12:48 +0000)
committerBruno Haible <bruno@clisp.org>
Wed, 11 Oct 2006 12:48:10 +0000 (12:48 +0000)
ChangeLog
lib/stpcpy.c
lib/strdup.c

index 4a246468fd905201c4be0ad8e24c0695a4528985..3859710e9738ec2f3ef756b87557108d3ca8ba5b 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,9 @@
+2006-10-10  Bruno Haible  <bruno@clisp.org>
+
+       Make it possible to #define stpcpy, strdup to aliases.
+       * lib/stpcpy.c (stpcpy) [!_LIBC]: Don't undefine.
+       * lib/strdup.c (strdup) [!_LIBC]: Don't undefine.
+
 2006-10-10  Bruno Haible  <bruno@clisp.org>
 
        Make it possible to #define gcd to an alias.
index 870fd6d4457da8cedfe32dc2acf5475a521ee170..4089d3946a4a24e6273435f44b9f949fda0f8d59 100644 (file)
@@ -23,7 +23,9 @@
 #include <string.h>
 
 #undef __stpcpy
-#undef stpcpy
+#ifdef _LIBC
+# undef stpcpy
+#endif
 
 #ifndef weak_alias
 # define __stpcpy stpcpy
index 7cff51be098deb0b5cc87f365356fb2ad0ba6574..17d40d622d8643198404668bf51d17297bd89b61 100644 (file)
@@ -27,7 +27,9 @@
 #include <string.h>
 
 #undef __strdup
-#undef strdup
+#ifdef _LIBC
+# undef strdup
+#endif
 
 #ifndef weak_alias
 # define __strdup strdup