summaryrefslogtreecommitdiff
path: root/source3/libsmb/samlogon_cache.c
diff options
context:
space:
mode:
authorVolker Lendecke <vl@samba.org>2010-01-10 17:39:27 +0100
committerVolker Lendecke <vl@samba.org>2010-01-10 20:56:16 +0100
commit3ea64e0ad86c35e5f0018ac60571e7a31a968543 (patch)
tree466ba7bc27e51491a9f64339e988a5468e5bd733 /source3/libsmb/samlogon_cache.c
parent50b7a3233f1edc184acb0b65870fff1db1226ef4 (diff)
downloadsamba-3ea64e0ad86c35e5f0018ac60571e7a31a968543.tar.gz
samba-3ea64e0ad86c35e5f0018ac60571e7a31a968543.tar.bz2
samba-3ea64e0ad86c35e5f0018ac60571e7a31a968543.zip
s3: Replace most calls to sid_append_rid() by sid_compose()
Diffstat (limited to 'source3/libsmb/samlogon_cache.c')
-rw-r--r--source3/libsmb/samlogon_cache.c6
1 files changed, 2 insertions, 4 deletions
diff --git a/source3/libsmb/samlogon_cache.c b/source3/libsmb/samlogon_cache.c
index 12901826ee..7339acb4d7 100644
--- a/source3/libsmb/samlogon_cache.c
+++ b/source3/libsmb/samlogon_cache.c
@@ -113,8 +113,7 @@ void netsamlogon_clear_cached_user(struct netr_SamInfo3 *info3)
NETSAMLOGON_TDB));
return;
}
- sid_copy(&user_sid, info3->base.domain_sid);
- sid_append_rid(&user_sid, info3->base.rid);
+ sid_compose(&user_sid, info3->base.domain_sid, info3->base.rid);
/* Prepare key as DOMAIN-SID/USER-RID string */
slprintf(keystr, sizeof(keystr), "%s", sid_to_fstring(tmp, &user_sid));
@@ -151,8 +150,7 @@ bool netsamlogon_cache_store(const char *username, struct netr_SamInfo3 *info3)
return false;
}
- sid_copy(&user_sid, info3->base.domain_sid);
- sid_append_rid(&user_sid, info3->base.rid);
+ sid_compose(&user_sid, info3->base.domain_sid, info3->base.rid);
/* Prepare key as DOMAIN-SID/USER-RID string */
slprintf(keystr, sizeof(keystr), "%s", sid_to_fstring(tmp, &user_sid));