]> granicus.if.org Git - php/commitdiff
The user argument cannot be NULL here - fixes 2 tests
authorRasmus Lerdorf <rasmus@php.net>
Thu, 6 Aug 2009 10:56:00 +0000 (10:56 +0000)
committerRasmus Lerdorf <rasmus@php.net>
Thu, 6 Aug 2009 10:56:00 +0000 (10:56 +0000)
ext/posix/posix.c

index 0230af73df92cb273af0c164812ad26d4db98b90..eda3ec4f8d6e9102c7d69139eb6c7a523e89eb31 100644 (file)
@@ -1390,6 +1390,8 @@ PHP_FUNCTION(posix_initgroups)
                RETURN_FALSE;
        }
 
+       if(strlen(name)==0) RETURN_FALSE;
+
        RETURN_BOOL(!initgroups((const char *)name, basegid));
 }
 /* }}} */