aboutsummaryrefslogtreecommitdiff
path: root/usr.bin/login
diff options
context:
space:
mode:
authorSheldon Hearn <sheldonh@FreeBSD.org>2000-04-26 10:38:19 +0000
committerSheldon Hearn <sheldonh@FreeBSD.org>2000-04-26 10:38:19 +0000
commit69f2cf17a3afcc7aeca0f1fb9c9d3fa94cfdf622 (patch)
treea65041a5d992e948144bee22fd5530743ea30d95 /usr.bin/login
parentd08ae64b1d3fb668e117609a3686913db9d9b507 (diff)
downloadsrc-69f2cf17a3afcc7aeca0f1fb9c9d3fa94cfdf622.tar.gz
src-69f2cf17a3afcc7aeca0f1fb9c9d3fa94cfdf622.zip
Add braces to avoid ambiguity in a nested conditional (silences a gcc
warning).
Notes
Notes: svn path=/head/; revision=59645
Diffstat (limited to 'usr.bin/login')
-rw-r--r--usr.bin/login/login.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/usr.bin/login/login.c b/usr.bin/login/login.c
index e6dc807909f1..967463c63356 100644
--- a/usr.bin/login/login.c
+++ b/usr.bin/login/login.c
@@ -766,7 +766,7 @@ getloginname()
if (p < nbuf + (NBUFSIZ - 1))
*p++ = ch;
}
- if (p > nbuf)
+ if (p > nbuf) {
if (nbuf[0] == '-')
(void)fprintf(stderr,
"login names may not start with '-'.\n");
@@ -775,6 +775,7 @@ getloginname()
username = nbuf;
break;
}
+ }
}
}