changeset 802:681cfbf19424 HEAD

unix98 says putenv() returns non-zero for errors - check for that rather than just negative values.
author Timo Sirainen <tss@iki.fi>
date Wed, 18 Dec 2002 06:05:11 +0200
parents 86224ff16bf6
children 960b35117c39
files src/lib/env-util.c
diffstat 1 files changed, 1 insertions(+), 1 deletions(-) [+]
line wrap: on
line diff
--- a/src/lib/env-util.c	Wed Dec 18 06:00:01 2002 +0200
+++ b/src/lib/env-util.c	Wed Dec 18 06:05:11 2002 +0200
@@ -35,7 +35,7 @@
 	if (pool == NULL)
 		pool = pool_create("Environment", 1024, FALSE);
 
-	if (putenv(p_strdup(pool, env)) < 0)
+	if (putenv(p_strdup(pool, env)) != 0)
 		i_fatal("Environment full, can't add: %s", env);
 }