summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAndrew Bartlett <abartlet@samba.org>2008-08-21 17:29:47 +1000
committerAndrew Bartlett <abartlet@samba.org>2008-08-21 17:29:47 +1000
commit38f740529803054a3145ad547b3d7de8a25e983a (patch)
treee6a3be1c950909bead4c15feeb0e5de68299a583
parent3d3fc7bdaaf41eb81ec7d653a68a3e4168c6177b (diff)
downloadsamba-38f740529803054a3145ad547b3d7de8a25e983a.tar.gz
samba-38f740529803054a3145ad547b3d7de8a25e983a.tar.bz2
samba-38f740529803054a3145ad547b3d7de8a25e983a.zip
Push loading the objectGUID and objectSID handlers earlier.
Andrew Bartlett (This used to be commit 0b6e53f80b063d8702718c84409d7b069aee9c05)
-rw-r--r--source4/lib/ldb_wrap.c12
1 files changed, 8 insertions, 4 deletions
diff --git a/source4/lib/ldb_wrap.c b/source4/lib/ldb_wrap.c
index 883597108a..6c683a1e33 100644
--- a/source4/lib/ldb_wrap.c
+++ b/source4/lib/ldb_wrap.c
@@ -147,17 +147,21 @@ struct ldb_context *ldb_wrap_connect(TALLOC_CTX *mem_ctx,
talloc_free(ldb);
return NULL;
}
-
- if (lp_ctx != NULL && strcmp(lp_sam_url(lp_ctx), url) == 0) {
- dsdb_set_global_schema(ldb);
- }
+ /* This must be done before we load the schema, as these
+ * handlers for objectSid and objectGUID etc must take
+ * precedence over the 'binary attribute' declaration in the
+ * schema */
ret = ldb_register_samba_handlers(ldb);
if (ret == -1) {
talloc_free(ldb);
return NULL;
}
+ if (lp_ctx != NULL && strcmp(lp_sam_url(lp_ctx), url) == 0) {
+ dsdb_set_global_schema(ldb);
+ }
+
ldb_set_debug(ldb, ldb_wrap_debug, NULL);
ldb_set_utf8_fns(ldb, NULL, wrap_casefold);