mirror of
https://github.com/samba-team/samba.git
synced 2025-02-07 01:58:28 +03:00
winbind: Use idmap_cache_find_xid2sid
Signed-off-by: Volker Lendecke <vl@samba.org> Reviewed-by: Christof Schmitt <cs@samba.org> Bug: https://bugzilla.samba.org/show_bug.cgi?id=13813 (cherry picked from commit bc9824bd42d9370279819ea0d927e236f6041324)
This commit is contained in:
parent
0a2db56732
commit
8d0a8864b1
@ -470,19 +470,8 @@ struct tevent_req *wb_xids2sids_send(TALLOC_CTX *mem_ctx,
|
||||
struct dom_sid sid = {0};
|
||||
bool ok, expired = true;
|
||||
|
||||
switch (xids[i].type) {
|
||||
case ID_TYPE_UID:
|
||||
ok = idmap_cache_find_uid2sid(
|
||||
xids[i].id, &sid, &expired);
|
||||
break;
|
||||
case ID_TYPE_GID:
|
||||
ok = idmap_cache_find_gid2sid(
|
||||
xids[i].id, &sid, &expired);
|
||||
break;
|
||||
default:
|
||||
ok = false;
|
||||
}
|
||||
|
||||
ok = idmap_cache_find_xid2sid(
|
||||
&xids[i], &sid, &expired);
|
||||
if (ok && !expired) {
|
||||
sid_copy(&state->sids[i], &sid);
|
||||
state->cached[i] = true;
|
||||
|
Loading…
x
Reference in New Issue
Block a user