summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAndrew Tridgell <tridge@samba.org>2010-01-10 12:52:22 +1100
committerAndrew Tridgell <tridge@samba.org>2010-01-10 13:23:37 +1100
commitd5091a1dd9cf669817355bb932249e5337e664b1 (patch)
tree872c88a872c3e06e5b03a0e7714fdfe54797ff8b
parentfd92db55eb613c5189f1a4aed719f77d47b80d68 (diff)
downloadsamba-d5091a1dd9cf669817355bb932249e5337e664b1.tar.gz
samba-d5091a1dd9cf669817355bb932249e5337e664b1.tar.bz2
samba-d5091a1dd9cf669817355bb932249e5337e664b1.zip
s4-dsdb: added samdb_domain_sid_cache_only()
-rw-r--r--source4/dsdb/common/util.c9
1 files changed, 8 insertions, 1 deletions
diff --git a/source4/dsdb/common/util.c b/source4/dsdb/common/util.c
index 139ea4dc6b..6147940e3b 100644
--- a/source4/dsdb/common/util.c
+++ b/source4/dsdb/common/util.c
@@ -1196,11 +1196,18 @@ const struct dom_sid *samdb_domain_sid(struct ldb_context *ldb)
return domain_sid;
failed:
- DEBUG(1,("Failed to find domain_sid for open ldb\n"));
talloc_free(tmp_ctx);
return NULL;
}
+/*
+ get domain sid from cache
+*/
+const struct dom_sid *samdb_domain_sid_cache_only(struct ldb_context *ldb)
+{
+ return (struct dom_sid *)ldb_get_opaque(ldb, "cache.domain_sid");
+}
+
bool samdb_set_domain_sid(struct ldb_context *ldb, const struct dom_sid *dom_sid_in)
{
TALLOC_CTX *tmp_ctx;