From: ghazi Date: Fri, 28 May 1999 07:34:48 +0000 (+0000) Subject: * putenv.c: Include ansidecl.h to define `const'. X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=3c243dede2f437903e413fc3e5bee12b1911b4e0;p=platform%2Fupstream%2Flinaro-gcc.git * putenv.c: Include ansidecl.h to define `const'. * setenv.c: Likewise. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@27221 138bc75d-0d04-0410-961f-82ee72b054a4 --- diff --git a/libiberty/ChangeLog b/libiberty/ChangeLog index 0c92dc1..cb77e8a 100644 --- a/libiberty/ChangeLog +++ b/libiberty/ChangeLog @@ -1,3 +1,8 @@ +1999-05-28 Kaveh R. Ghazi + + * putenv.c: Include ansidecl.h to define `const'. + * setenv.c: Likewise. + Wed May 26 03:58:20 1999 "Melissa O'Neill" * Makefile.in (CFILES): Add putenv.c and setenv.c. diff --git a/libiberty/putenv.c b/libiberty/putenv.c index 1860676..9d56922 100644 --- a/libiberty/putenv.c +++ b/libiberty/putenv.c @@ -24,6 +24,8 @@ # include #endif +#include "ansidecl.h" + #if HAVE_STDLIB_H # include #endif @@ -55,7 +57,7 @@ putenv (string) if (name_end) { - char *name = alloca (name_end - string + 1); + char *name = (char *) alloca (name_end - string + 1); memcpy (name, string, name_end - string); name[name_end - string] = '\0'; return setenv (name, name_end + 1, 1); diff --git a/libiberty/setenv.c b/libiberty/setenv.c index 0ecc2ca..8a039d1 100644 --- a/libiberty/setenv.c +++ b/libiberty/setenv.c @@ -20,6 +20,8 @@ # include #endif +#include "ansidecl.h" + #include #if !defined(errno) && !defined(HAVE_ERRNO_DECL) extern int errno;