Try and fix the buildfarm by using getpwnam(root) instead
authorJeremy Allison <jra@samba.org>
Sat, 22 Aug 2009 04:08:02 +0000 (21:08 -0700)
committerJeremy Allison <jra@samba.org>
Sat, 22 Aug 2009 04:08:02 +0000 (21:08 -0700)
of getpwuid(0) if DEVELOPER is defined. I'm hoping the
build farm defines DEVELOPER...
Jeremy.

source3/auth/token_util.c

index 8e8e604702adadf5804045cde4b5ffcabcf47314..45b0fe2938956b87a88c4a0542ac3f032b11a6d5 100644 (file)
@@ -91,10 +91,17 @@ NT_USER_TOKEN *get_root_nt_token( void )
                        cache_data, struct nt_user_token);
        }
 
+#if defined(DEVELOPER)
+       if ( !(pw = sys_getpwnam("root")) ) {
+               DEBUG(0,("get_root_nt_token: sys_getpwnam(\"root\") failed!\n"));
+               return NULL;
+       }
+#else
        if ( !(pw = sys_getpwuid(0)) ) {
                DEBUG(0,("get_root_nt_token: sys_getpwuid(0) failed!\n"));
                return NULL;
        }
+#endif
 
        /* get the user and primary group SIDs; although the
           BUILTIN\Administrators SId is really the one that matters here */