$NetBSD: patch-ah,v 1.2 2010/12/03 21:21:11 ghen Exp $

--- src/lib/env-util.c.orig	2010-11-10 16:09:10.000000000 +0000
+++ src/lib/env-util.c
@@ -59,7 +59,11 @@ void env_clean(void)
 	if (clearenv() < 0)
 		i_fatal("clearenv() failed");
 #else
+#ifdef __APPLE__
+	char **environ = *_NSGetEnviron();
+#else
 	extern char **environ;
+#endif
 
 	/* Try to clear the environment.
 
