]> git.cameronkatri.com Git - pw-darwin.git/commitdiff
Regression fix: allow to create users with uid0
authorBaptiste Daroussin <bapt@FreeBSD.org>
Mon, 13 Jul 2015 09:08:27 +0000 (09:08 +0000)
committerBaptiste Daroussin <bapt@FreeBSD.org>
Mon, 13 Jul 2015 09:08:27 +0000 (09:08 +0000)
Reported by: Jan Mikkelsen <janm@transactionware.com>

pw/pw_user.c

index 8ba2807dcbdf06bf34c001bd4f17b99b4a2a7649..d6dad3f3c52b7ea121826a2c704633362301c882 100644 (file)
@@ -804,7 +804,7 @@ pw_uidpolicy(struct userconf * cnf, long id)
        /*
         * Check the given uid, if any
         */
-       if (id > 0) {
+       if (id >= 0) {
                uid = (uid_t) id;
 
                if ((pwd = GETPWUID(uid)) != NULL && conf.checkduplicate)