summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorpjanzen <pjanzen@openbsd.org>2001-02-13 14:48:40 +0000
committerpjanzen <pjanzen@openbsd.org>2001-02-13 14:48:40 +0000
commit18ddd2175e7d8379a18345822d2fecc914ade112 (patch)
treebec79228c265d5589a64caac6f60722a579ce950
parentKNF (diff)
downloadwireguard-openbsd-18ddd2175e7d8379a18345822d2fecc914ade112.tar.xz
wireguard-openbsd-18ddd2175e7d8379a18345822d2fecc914ade112.zip
_PW_NAME_LEN doesn't include the NUL, MAXLOGNAME does.
-rw-r--r--include/pwd.h7
1 files changed, 4 insertions, 3 deletions
diff --git a/include/pwd.h b/include/pwd.h
index 0c3ec950a66..af6c812f619 100644
--- a/include/pwd.h
+++ b/include/pwd.h
@@ -1,4 +1,4 @@
-/* $OpenBSD: pwd.h,v 1.10 2001/01/31 17:42:25 deraadt Exp $ */
+/* $OpenBSD: pwd.h,v 1.11 2001/02/13 14:48:40 pjanzen Exp $ */
/* $NetBSD: pwd.h,v 1.9 1996/05/15 21:36:45 jtc Exp $ */
/*-
@@ -66,8 +66,9 @@
#define _PASSWORD_EFMT1 '_' /* extended encryption format */
-#define _PASSWORD_LEN 128 /* max length, not counting NULL */
-#define _PW_NAME_LEN 32 /* max length, not counting NULL */
+#define _PASSWORD_LEN 128 /* max length, not counting NUL */
+#define _PW_NAME_LEN 31 /* max length, not counting NUL */
+ /* Should be MAXLOGNAME - 1 */
#define _PASSWORD_NOUID 0x01 /* flag for no specified uid. */
#define _PASSWORD_NOGID 0x02 /* flag for no specified gid. */