mirror of git://gcc.gnu.org/git/gcc.git
putenv.c: Include ansidecl.h to define `const'.
* putenv.c: Include ansidecl.h to define `const'. * setenv.c: Likewise. From-SVN: r27221
This commit is contained in:
parent
77b7d85187
commit
fee9125c10
|
@ -1,3 +1,8 @@
|
||||||
|
1999-05-28 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
|
||||||
|
|
||||||
|
* putenv.c: Include ansidecl.h to define `const'.
|
||||||
|
* setenv.c: Likewise.
|
||||||
|
|
||||||
Wed May 26 03:58:20 1999 "Melissa O'Neill" <oneill@cs.sfu.ca>
|
Wed May 26 03:58:20 1999 "Melissa O'Neill" <oneill@cs.sfu.ca>
|
||||||
|
|
||||||
* Makefile.in (CFILES): Add putenv.c and setenv.c.
|
* Makefile.in (CFILES): Add putenv.c and setenv.c.
|
||||||
|
|
|
@ -24,6 +24,8 @@
|
||||||
# include <config.h>
|
# include <config.h>
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
#include "ansidecl.h"
|
||||||
|
|
||||||
#if HAVE_STDLIB_H
|
#if HAVE_STDLIB_H
|
||||||
# include <stdlib.h>
|
# include <stdlib.h>
|
||||||
#endif
|
#endif
|
||||||
|
@ -55,7 +57,7 @@ putenv (string)
|
||||||
|
|
||||||
if (name_end)
|
if (name_end)
|
||||||
{
|
{
|
||||||
char *name = alloca (name_end - string + 1);
|
char *name = (char *) alloca (name_end - string + 1);
|
||||||
memcpy (name, string, name_end - string);
|
memcpy (name, string, name_end - string);
|
||||||
name[name_end - string] = '\0';
|
name[name_end - string] = '\0';
|
||||||
return setenv (name, name_end + 1, 1);
|
return setenv (name, name_end + 1, 1);
|
||||||
|
|
|
@ -20,6 +20,8 @@
|
||||||
# include <config.h>
|
# include <config.h>
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
#include "ansidecl.h"
|
||||||
|
|
||||||
#include <errno.h>
|
#include <errno.h>
|
||||||
#if !defined(errno) && !defined(HAVE_ERRNO_DECL)
|
#if !defined(errno) && !defined(HAVE_ERRNO_DECL)
|
||||||
extern int errno;
|
extern int errno;
|
||||||
|
|
Loading…
Reference in New Issue