diff options
author | martin <martin@FreeBSD.org> | 1996-07-03 21:43:48 +0000 |
---|---|---|
committer | martin <martin@FreeBSD.org> | 1996-07-03 21:43:48 +0000 |
commit | c42838f64b3da632a6b2e97be219ee7089c51612 (patch) | |
tree | a85b1d69fb3341ebda66d6b7db9837274be9f811 /usr.sbin/pwd_mkdb/pwd_mkdb.c | |
parent | 91664726c6532bcbe44c6cafbf0ef8b0d10d9384 (diff) | |
download | FreeBSD-src-c42838f64b3da632a6b2e97be219ee7089c51612.zip FreeBSD-src-c42838f64b3da632a6b2e97be219ee7089c51612.tar.gz |
Check if username is a NULL pointer before dereferencing it.
Diffstat (limited to 'usr.sbin/pwd_mkdb/pwd_mkdb.c')
-rw-r--r-- | usr.sbin/pwd_mkdb/pwd_mkdb.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/usr.sbin/pwd_mkdb/pwd_mkdb.c b/usr.sbin/pwd_mkdb/pwd_mkdb.c index fc2f893..14df812 100644 --- a/usr.sbin/pwd_mkdb/pwd_mkdb.c +++ b/usr.sbin/pwd_mkdb/pwd_mkdb.c @@ -125,7 +125,7 @@ main(argc, argv) argc -= optind; argv += optind; - if (argc != 1 || *username == '+' || *username == '-') + if (argc != 1 || (username && (*username == '+' || *username == '-'))) usage(); /* |