setenv: Avoid gcc warning.
authorBruno Haible <bruno@clisp.org>
Sun, 5 Jun 2011 12:31:51 +0000 (14:31 +0200)
committerBruno Haible <bruno@clisp.org>
Sun, 5 Jun 2011 12:31:51 +0000 (14:31 +0200)
* lib/setenv.c (setenv): Provide declaration if system lacks it.

ChangeLog
lib/setenv.c

index 599c20d464fae3aac8ccb5016a66d793e0b70528..5fdf8a49f5c2232ec4418685eb6e1d2ab5607762 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,8 @@
+2011-06-05  Bruno Haible  <bruno@clisp.org>
+
+       setenv: Avoid gcc warning.
+       * lib/setenv.c (setenv): Provide declaration if system lacks it.
+
 2011-06-05  Bruno Haible  <bruno@clisp.org>
 
        sys_select: Ensure memset is declared also on AIX 7.
index 173d95f28b4853599777e28f7d20fdb7d32cd904..0a5f67dd044a8ee57c28025564798ae5d6fad6dc 100644 (file)
@@ -350,6 +350,9 @@ weak_alias (__clearenv, clearenv)
 #if HAVE_SETENV
 
 # undef setenv
+# if !HAVE_DECL_SETENV
+extern int setenv (const char *, const char *, int);
+# endif
 # define STREQ(a, b) (strcmp (a, b) == 0)
 
 int