diff options
author | Theo de Raadt <deraadt@cvs.openbsd.org> | 1998-06-10 09:00:49 +0000 |
---|---|---|
committer | Theo de Raadt <deraadt@cvs.openbsd.org> | 1998-06-10 09:00:49 +0000 |
commit | b1cdfb4914a096f5c2893f9a5d29313ea7eca473 (patch) | |
tree | b9e335ef9ee4e90a1c216ba7cd3a1cae3c867b05 /usr.sbin | |
parent | 00ac48fa029432909e9fc923a68c3413417e0bce (diff) |
clear flag before pw_scan(); lukem
Diffstat (limited to 'usr.sbin')
-rw-r--r-- | usr.sbin/pwd_mkdb/pwd_mkdb.c | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/usr.sbin/pwd_mkdb/pwd_mkdb.c b/usr.sbin/pwd_mkdb/pwd_mkdb.c index 37ded169aa9..25252128ee2 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.14 1998/04/26 10:10:51 deraadt Exp $ */ +/* $OpenBSD: pwd_mkdb.c,v 1.15 1998/06/10 09:00:48 deraadt Exp $ */ /*- * Copyright (c) 1991, 1993, 1994 @@ -44,7 +44,7 @@ static char copyright[] = #if 0 static char sccsid[] = "from: @(#)pwd_mkdb.c 8.5 (Berkeley) 4/20/94"; #else -static char *rcsid = "$OpenBSD: pwd_mkdb.c,v 1.14 1998/04/26 10:10:51 deraadt Exp $"; +static char *rcsid = "$OpenBSD: pwd_mkdb.c,v 1.15 1998/06/10 09:00:48 deraadt Exp $"; #endif #endif /* not lint */ @@ -100,7 +100,7 @@ main(argc, argv) FILE *fp, *oldfp; struct stat st; sigset_t set; - int ch, cnt, len, makeold, tfd, flags; + int ch, cnt, len, makeold, tfd, flags = 0; char *p, *t; char buf[MAX(MAXPATHLEN, LINE_MAX * 2)], tbuf[1024]; int hasyp = 0; @@ -418,6 +418,7 @@ scan(fp, pw, flags) } *p = '\0'; + *flags = 0; if (!pw_scan(line, pw, flags)) { warnx("at line #%d", lcnt); fmt: errno = EFTYPE; /* XXX */ |