From: Jim Meyering Date: Wed, 10 Sep 2003 09:07:43 +0000 (+0000) Subject: (malloc): Returns void *, not char *. X-Git-Tag: COREUTILS-5_1_0~736 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=548b033dd6a3698befd21e5d928e4129a8538688;p=platform%2Fupstream%2Fcoreutils.git (malloc): Returns void *, not char *. Include unconditionally. (strchr, memcpy, NULL): Do not define. --- diff --git a/lib/putenv.c b/lib/putenv.c index f5ce1dd..87c5522 100644 --- a/lib/putenv.c +++ b/lib/putenv.c @@ -37,23 +37,15 @@ extern int errno; with a non-const argument. That would conflict with the declaration of rpl_putenv below (due to the #define putenv rpl_putenv from config.h). */ -char *malloc (); +void *malloc (); void free (); -#if defined (__GNU_LIBRARY__) || defined (HAVE_STRING_H) -# include -#endif +#include + #if defined (__GNU_LIBRARY__) || defined (HAVE_UNISTD_H) # include #endif -#if !defined (__GNU_LIBRARY__) && !defined (HAVE_STRCHR) -# define strchr index -#endif -#if !defined (__GNU_LIBRARY__) && !defined (HAVE_MEMCPY) -# define memcpy(d,s,n) bcopy ((s), (d), (n)) -#endif - #if HAVE_GNU_LD # define environ __environ #else @@ -71,10 +63,6 @@ __libc_lock_define_initialized (static, envlock) # define UNLOCK #endif -#ifndef NULL -# define NULL 0 -#endif - static int unsetenv (const char *name) {