diff options
Diffstat (limited to 'nsswitch')
-rw-r--r-- | nsswitch/libwbclient/wbc_idmap.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/nsswitch/libwbclient/wbc_idmap.c b/nsswitch/libwbclient/wbc_idmap.c index ad3cfe67709..5325dbe5ce5 100644 --- a/nsswitch/libwbclient/wbc_idmap.c +++ b/nsswitch/libwbclient/wbc_idmap.c @@ -372,10 +372,10 @@ wbcErr wbcSidsToUnixIds(const struct wbcDomainSid *sids, uint32_t num_sids, break; default: id->type = WBC_ID_TYPE_NOT_SPECIFIED; - q = p; + q = strchr(p, '\n'); break; }; - if (q[0] != '\n') { + if (q == NULL || q[0] != '\n') { goto wbc_err_invalid; } p = q+1; |