]> git.cameronkatri.com Git - pw-darwin.git/blobdiff - pw/pw_conf.c
Clean up the vcs ID strings in libc's gen/ directory.
[pw-darwin.git] / pw / pw_conf.c
index a3bd0bd367333a7876bf70ee3d9b8b191bb1d383..36bb8b61e9d14b0e7b63d2b3034c9e72578db2b5 100644 (file)
@@ -1,4 +1,6 @@
 /*-
+ * SPDX-License-Identifier: BSD-2-Clause-FreeBSD
+ *
  * Copyright (C) 1996
  *     David L. Nugent.  All rights reserved.
  *
@@ -198,18 +200,18 @@ passwd_val(char const * str, int dflt)
 
                for (i = 0; booltrue[i]; i++)
                        if (strcmp(str, booltrue[i]) == 0)
-                               return 1;
+                               return P_YES;
                for (i = 0; boolfalse[i]; i++)
                        if (strcmp(str, boolfalse[i]) == 0)
-                               return 0;
+                               return P_NO;
 
                /*
                 * Special cases for defaultpassword
                 */
                if (strcmp(str, "random") == 0)
-                       return -1;
+                       return P_RANDOM;
                if (strcmp(str, "none") == 0)
-                       return -2;
+                       return P_NONE;
 
                errx(1, "Invalid value for default password");
        }