From b1daa1b9db90baacab8a5d04ba07d2405e25f6a8 Mon Sep 17 00:00:00 2001 From: Brian Somers Date: Wed, 20 Sep 2000 03:05:37 +0000 Subject: Only realloc() environ if we're sure that we know where it came from. The recent problems with sshd were due to sshd reassigning `environ' when setenv() thinks it owns it. setenv() subsequently realloc()s the new version of environ and *boom* --- lib/libc/stdlib/malloc.c | 1 + 1 file changed, 1 insertion(+) (limited to 'lib/libc/stdlib/malloc.c') diff --git a/lib/libc/stdlib/malloc.c b/lib/libc/stdlib/malloc.c index 3b631e86de79..1bcc5e1416c1 100644 --- a/lib/libc/stdlib/malloc.c +++ b/lib/libc/stdlib/malloc.c @@ -20,6 +20,7 @@ #ifndef MALLOC_EXTRA_SANITY #undef MALLOC_EXTRA_SANITY #endif +#define MALLOC_EXTRA_SANITY /* * What to use for Junk. This is the byte value we use to fill with -- cgit v1.2.3