]> granicus.if.org Git - sudo/commitdiff
Fix unsetenv when UNSETENV_VOID
authorTodd C. Miller <Todd.Miller@courtesan.com>
Mon, 2 Mar 2009 19:18:35 +0000 (19:18 +0000)
committerTodd C. Miller <Todd.Miller@courtesan.com>
Mon, 2 Mar 2009 19:18:35 +0000 (19:18 +0000)
env.c

diff --git a/env.c b/env.c
index 4a7a0ea32d106df3dccb161b73ce1cc5026bc798..51704c890ffa4fae15b06e4275403e6d6ccdf0c0 100644 (file)
--- a/env.c
+++ b/env.c
@@ -286,7 +286,11 @@ unsetenv(var)
 
     if (strchr(var, '=') != NULL) {
        errno = EINVAL;
+#ifndef UNSETENV_VOID
+       return;
+#else
        return(-1);
+#endif
     }
 
     /* Make sure we are operating on the current environment. */