summaryrefslogtreecommitdiffstats
path: root/usr.bin
diff options
context:
space:
mode:
authorbde <bde@FreeBSD.org>1999-07-02 11:20:59 +0000
committerbde <bde@FreeBSD.org>1999-07-02 11:20:59 +0000
commitae73a7933284521689089923d4b4aa853b4e0fa7 (patch)
treef05dc11921fad2b9d85c9cbdda78ba2495ea6329 /usr.bin
parent090af66e8b5a9493ccbededf86c1bf70c7fb9ca2 (diff)
downloadFreeBSD-src-ae73a7933284521689089923d4b4aa853b4e0fa7.zip
FreeBSD-src-ae73a7933284521689089923d4b4aa853b4e0fa7.tar.gz
Actually fixed ambiguous else. The previous revision had no effect.
Diffstat (limited to 'usr.bin')
-rw-r--r--usr.bin/su/su.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/usr.bin/su/su.c b/usr.bin/su/su.c
index 390611d..4029839 100644
--- a/usr.bin/su/su.c
+++ b/usr.bin/su/su.c
@@ -42,7 +42,7 @@ static const char copyright[] =
static char sccsid[] = "@(#)su.c 8.3 (Berkeley) 4/2/94";
#endif
static const char rcsid[] =
- "$Id: su.c,v 1.29 1998/10/09 20:14:48 markm Exp $";
+ "$Id: su.c,v 1.30 1999/07/01 17:59:17 billf Exp $";
#endif /* not lint */
#include <sys/param.h>
@@ -269,12 +269,12 @@ main(argc, argv)
if (pwd->pw_uid == 0 && (gr = getgrgid((gid_t)0)) &&
gr->gr_mem && *(gr->gr_mem))
for (g = gr->gr_mem;; ++g) {
- if (!*g)
+ if (!*g) {
if (gid == 0)
break;
- else {
+ else
errx(1, "you are not in the correct group to su %s.", user);
- }
+ }
if (strcmp(username, *g) == 0) {
#ifdef WHEELSU
iswheelsu = 1;
OpenPOWER on IntegriCloud