runas_pw can no longer be NULL here

This commit is contained in:
Todd C. Miller
2016-09-15 09:40:41 -06:00
parent ef82f792a1
commit d2af18c1fa

View File

@@ -216,7 +216,7 @@ runaslist_matches(const struct member_list *user_list,
*/ */
if (runas_gr != NULL) { if (runas_gr != NULL) {
if (user_matched == UNSPEC) { if (user_matched == UNSPEC) {
if (runas_pw == NULL || strcmp(runas_pw->pw_name, user_name) == 0) if (strcmp(runas_pw->pw_name, user_name) == 0)
user_matched = ALLOW; /* only changing group */ user_matched = ALLOW; /* only changing group */
} }
if (group_list != NULL) { if (group_list != NULL) {