]> git.saurik.com Git - apple/libc.git/blob - stdlib/FreeBSD/getenv.c.patch
12472a37d129a0d20fe347d40dedc6de50a0af6f
[apple/libc.git] / stdlib / FreeBSD / getenv.c.patch
1 --- getenv.c.orig Mon Apr 28 16:37:26 2003
2 +++ getenv.c Sat May 3 14:29:07 2003
3 @@ -40,6 +40,7 @@
4 #include <stdlib.h>
5 #include <stddef.h>
6 #include <string.h>
7 +#include <crt_externs.h>
8
9 inline char *__findenv(const char *, int *);
10
11 @@ -57,7 +58,7 @@
12 const char *name;
13 int *offset;
14 {
15 - extern char **environ;
16 + char **environ = *_NSGetEnviron();
17 int len, i;
18 const char *np;
19 char **p, *cp;