summaryrefslogtreecommitdiff
path: root/usr.sbin/pwd_mkdb/pwd_mkdb.c
diff options
context:
space:
mode:
authorTodd C. Miller <millert@cvs.openbsd.org>2008-06-25 14:51:28 +0000
committerTodd C. Miller <millert@cvs.openbsd.org>2008-06-25 14:51:28 +0000
commit3eb98ad5a38d8d95544673bda852f357b1070ff5 (patch)
treea23973fa8f1fb34ddf8e480f9fbc06df0cadda70 /usr.sbin/pwd_mkdb/pwd_mkdb.c
parentbd9c7c00ea19428f1c5a104e266f09a3dc31c43c (diff)
Add _PW_BUF_LEN define and use it instead of hard-coding 1024 for
the buffer size. OK deraadt@
Diffstat (limited to 'usr.sbin/pwd_mkdb/pwd_mkdb.c')
-rw-r--r--usr.sbin/pwd_mkdb/pwd_mkdb.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/usr.sbin/pwd_mkdb/pwd_mkdb.c b/usr.sbin/pwd_mkdb/pwd_mkdb.c
index b55eec1d7dd..17493cf48ef 100644
--- a/usr.sbin/pwd_mkdb/pwd_mkdb.c
+++ b/usr.sbin/pwd_mkdb/pwd_mkdb.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: pwd_mkdb.c,v 1.39 2008/03/17 20:30:16 sobrado Exp $ */
+/* $OpenBSD: pwd_mkdb.c,v 1.40 2008/06/25 14:51:27 millert Exp $ */
/*-
* Copyright (c) 1991, 1993, 1994
@@ -41,7 +41,7 @@ static const char copyright[] =
#if 0
static const char sccsid[] = "from: @(#)pwd_mkdb.c 8.5 (Berkeley) 4/20/94";
#else
-static const char rcsid[] = "$OpenBSD: pwd_mkdb.c,v 1.39 2008/03/17 20:30:16 sobrado Exp $";
+static const char rcsid[] = "$OpenBSD: pwd_mkdb.c,v 1.40 2008/06/25 14:51:27 millert Exp $";
#endif
#endif /* not lint */
@@ -490,7 +490,7 @@ void
db_store(FILE *fp, FILE *oldfp, DB *edp, DB *dp, struct passwd *pw,
int keytype, char *username, uid_t olduid)
{
- char *p, *t, buf[LINE_MAX * 2], tbuf[1024];
+ char *p, *t, buf[LINE_MAX * 2], tbuf[_PW_BUF_LEN];
int flags = 0, dbmode, found = 0;
static int firsttime = 1;
DBT data, key;