diff options
| author | Xin LI <delphij@FreeBSD.org> | 2011-10-16 07:05:43 +0000 |
|---|---|---|
| committer | Xin LI <delphij@FreeBSD.org> | 2011-10-16 07:05:43 +0000 |
| commit | 41cbfdc95445e800b676aafd971fe7ef45457584 (patch) | |
| tree | 49d45572607d22e9a366b985efa53be3634ff891 /usr.bin/newgrp | |
| parent | 5d9fefacf242fc8db7b169257fab739c798bfe77 (diff) | |
Notes
Diffstat (limited to 'usr.bin/newgrp')
| -rw-r--r-- | usr.bin/newgrp/newgrp.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/usr.bin/newgrp/newgrp.c b/usr.bin/newgrp/newgrp.c index 81983011ce65..5381b15555fb 100644 --- a/usr.bin/newgrp/newgrp.c +++ b/usr.bin/newgrp/newgrp.c @@ -220,7 +220,7 @@ addgroup(const char *grpname) /* Add old effective gid to supp. list if it does not exist. */ if (egid != grp->gr_gid && !inarray(egid, grps, ngrps)) { - if (ngrps + 1 >= ngrps_max) + if (ngrps == ngrps_max) warnx("too many groups"); else { grps[ngrps++] = egid; |
