diff options
| author | Marcelo Araujo <araujo@FreeBSD.org> | 2016-04-18 05:26:32 +0000 |
|---|---|---|
| committer | Marcelo Araujo <araujo@FreeBSD.org> | 2016-04-18 05:26:32 +0000 |
| commit | 6a3f9a213ac91dddaf920283beae38fde6b10a89 (patch) | |
| tree | 3f324dea5ed04fb07c6e4a01e436b6766452552f /usr.bin/login | |
| parent | bb0bd931dc6ac74463ac169a03fe14ef425b1d3d (diff) | |
Notes
Diffstat (limited to 'usr.bin/login')
| -rw-r--r-- | usr.bin/login/login_fbtab.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/usr.bin/login/login_fbtab.c b/usr.bin/login/login_fbtab.c index 8faee56b71c9..f4f0516a5a3c 100644 --- a/usr.bin/login/login_fbtab.c +++ b/usr.bin/login/login_fbtab.c @@ -96,15 +96,15 @@ login_fbtab(char *tty, uid_t uid, gid_t gid) while (fgets(buf, sizeof(buf), fp)) { if ((cp = strchr(buf, '#'))) *cp = 0; /* strip comment */ - if ((cp = devname = strtok(buf, WSPACE)) == 0) + if ((cp = devname = strtok(buf, WSPACE)) == NULL) continue; /* empty or comment */ if (strncmp(devname, _PATH_DEV, sizeof _PATH_DEV - 1) != 0 - || (cp = strtok(NULL, WSPACE)) == 0 + || (cp = strtok(NULL, WSPACE)) == NULL || *cp != '0' || sscanf(cp, "%o", &prot) == 0 || prot == 0 || (prot & 0777) != prot - || (cp = strtok(NULL, WSPACE)) == 0) { + || (cp = strtok(NULL, WSPACE)) == NULL) { syslog(LOG_ERR, "%s: bad entry: %s", table, cp ? cp : "(null)"); continue; } |
