dovecot-2.0-sslstream: Check return value if unsetenv().

dovecot at dovecot.org dovecot at dovecot.org
Sat Feb 13 02:56:46 EET 2010


details:   http://hg.dovecot.org/dovecot-2.0-sslstream/rev/927cc04cd5e8
changeset: 10414:927cc04cd5e8
user:      Timo Sirainen <tss at iki.fi>
date:      Fri Dec 04 16:53:58 2009 -0600
description:
Check return value if unsetenv().

diffstat:

1 file changed, 2 insertions(+), 1 deletion(-)
src/lib/env-util.c |    3 ++-

diffs (13 lines):

diff -r a9eda7672869 -r 927cc04cd5e8 src/lib/env-util.c
--- a/src/lib/env-util.c	Fri Dec 04 16:15:51 2009 -0600
+++ b/src/lib/env-util.c	Fri Dec 04 16:53:58 2009 -0600
@@ -25,7 +25,8 @@ void env_remove(const char *name)
 void env_remove(const char *name)
 {
 #ifdef HAVE_UNSETENV
-	unsetenv(name);
+	if (unsetenv(name) < 0)
+		i_fatal("unsetenv(%s) failed: %m", name);
 #else
 	extern char **environ;
 	unsigned int len;


More information about the dovecot-cvs mailing list