summaryrefslogtreecommitdiffstats
path: root/pw/pw_user.c
diff options
context:
space:
mode:
authorBaptiste Daroussin <bapt@FreeBSD.org>2015-06-07 11:38:26 +0000
committerBaptiste Daroussin <bapt@FreeBSD.org>2015-06-07 11:38:26 +0000
commitad2778a7ba836f39b9761eacc101a91f599cf40e (patch)
tree3f805cebe7468545561de8d78334d211214daf84 /pw/pw_user.c
parent704e1b49938e3613cff8e9ac9251bcfc55aca739 (diff)
downloadpw-darwin-ad2778a7ba836f39b9761eacc101a91f599cf40e.tar.gz
pw-darwin-ad2778a7ba836f39b9761eacc101a91f599cf40e.tar.zst
pw-darwin-ad2778a7ba836f39b9761eacc101a91f599cf40e.zip
Test explicitly the result of strcmp to be consistent with the rest of the code
Diffstat (limited to 'pw/pw_user.c')
-rw-r--r--pw/pw_user.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/pw/pw_user.c b/pw/pw_user.c
index dc33272..5f65129 100644
--- a/pw/pw_user.c
+++ b/pw/pw_user.c
@@ -1126,7 +1126,7 @@ delete_user(struct userconf *cnf, struct passwd *pwd, struct carg *a_name,
continue;
for (i = 0; grp->gr_mem[i] != NULL; i++) {
- if (strcmp(grp->gr_mem[i], a_name->val))
+ if (strcmp(grp->gr_mem[i], a_name->val) != 0)
continue;
for (j = i; grp->gr_mem[j] != NULL; j++)