svn commit: samba r17072 - in branches/SOC/mkhl/ldb-map/modules: .
mkhl at samba.org
mkhl at samba.org
Sat Jul 15 18:35:26 GMT 2006
Author: mkhl
Date: 2006-07-15 18:35:26 +0000 (Sat, 15 Jul 2006)
New Revision: 17072
WebSVN: http://websvn.samba.org/cgi-bin/viewcvs.cgi?view=rev&root=samba&rev=17072
Log:
When a parse-tree contains only remote parts, use a new parse-tree
that searches records pointing to remote parts for the local search.
Martin
Modified:
branches/SOC/mkhl/ldb-map/modules/ldb_map.c
Changeset:
Modified: branches/SOC/mkhl/ldb-map/modules/ldb_map.c
===================================================================
--- branches/SOC/mkhl/ldb-map/modules/ldb_map.c 2006-07-15 18:33:32 UTC (rev 17071)
+++ branches/SOC/mkhl/ldb-map/modules/ldb_map.c 2006-07-15 18:35:26 UTC (rev 17072)
@@ -2073,6 +2073,19 @@
if (ret != LDB_SUCCESS)
goto failed;
+ /* if there is no local tree, search for records with remote parts */
+ if (remote_tree && !local_tree) {
+ local_tree = talloc_zero(ac->local_req, struct ldb_parse_tree);
+ if (local_tree == NULL) {
+ map_oom(module);
+ goto failed;
+ }
+
+ local_tree->operation = LDB_OP_PRESENT;
+ local_tree->u.present.attr
+ = talloc_strdup(local_tree, IS_MAPPED);
+ }
+
ac->local_req->op.search.tree = local_tree;
ac->remote_tree = remote_tree;
More information about the samba-cvs
mailing list