diff options
author | Günther Deschner <gd@samba.org> | 2006-01-09 12:59:41 +0000 |
---|---|---|
committer | Gerald (Jerry) Carter <jerry@samba.org> | 2007-10-10 11:06:03 -0500 |
commit | 1e9d8d485791282f860a0a3c46234c128b84b3a0 (patch) | |
tree | 7669536c9c360eea5cd33f57e4ad58f611a0e613 /source3/nsswitch | |
parent | 7745148580cc9ab71d2335d55fc63dae4c021662 (diff) | |
download | samba-1e9d8d485791282f860a0a3c46234c128b84b3a0.tar.gz samba-1e9d8d485791282f860a0a3c46234c128b84b3a0.tar.bz2 samba-1e9d8d485791282f860a0a3c46234c128b84b3a0.zip |
r12788: Since we have agreed on the case of winbindd names, we can store a
sid_to_name lookup result already after doing a sucessfull name_to_sid
lookup.
Guenther
(This used to be commit 2456832a6d9ad2590dc02e147cc2c2e87d5a3a7a)
Diffstat (limited to 'source3/nsswitch')
-rw-r--r-- | source3/nsswitch/winbindd_cache.c | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/source3/nsswitch/winbindd_cache.c b/source3/nsswitch/winbindd_cache.c index 81dd85e588..1d047b8356 100644 --- a/source3/nsswitch/winbindd_cache.c +++ b/source3/nsswitch/winbindd_cache.c @@ -991,8 +991,11 @@ do_query: /* and save it */ wcache_save_name_to_sid(domain, status, domain_name, name, sid, *type); - /* We can't save the sid to name mapping as we don't know the - correct case of the name without looking it up */ + if (NT_STATUS_IS_OK(status)) { + strupper_m(CONST_DISCARD(char *,domain_name)); + strlower_m(CONST_DISCARD(char *,name)); + wcache_save_sid_to_name(domain, status, sid, domain_name, name, *type); + } return status; } |