diff options
author | Andrew Tridgell <tridge@samba.org> | 2011-01-17 13:39:46 +1100 |
---|---|---|
committer | Andrew Tridgell <tridge@samba.org> | 2011-01-17 05:23:04 +0100 |
commit | 8794e6dad906b9cc1eefbe03665a0035b91ac199 (patch) | |
tree | cf6e9c809ad9791333f397237139b370994f60d7 /source4/dsdb/samdb/ldb_modules/samldb.c | |
parent | 87f31510475c6debd56ff874130f4f5d48bef9a5 (diff) | |
download | samba-8794e6dad906b9cc1eefbe03665a0035b91ac199.tar.gz samba-8794e6dad906b9cc1eefbe03665a0035b91ac199.tar.bz2 samba-8794e6dad906b9cc1eefbe03665a0035b91ac199.zip |
s4-dsdb: replaced the calls to ldb_search() in dsdb modules with dsdb_module_search()
this ensures we follow the module stack, and set the parent on child
requests
Diffstat (limited to 'source4/dsdb/samdb/ldb_modules/samldb.c')
-rw-r--r-- | source4/dsdb/samdb/ldb_modules/samldb.c | 21 |
1 files changed, 11 insertions, 10 deletions
diff --git a/source4/dsdb/samdb/ldb_modules/samldb.c b/source4/dsdb/samdb/ldb_modules/samldb.c index 53c45e62bc..ee0d66cc04 100644 --- a/source4/dsdb/samdb/ldb_modules/samldb.c +++ b/source4/dsdb/samdb/ldb_modules/samldb.c @@ -1075,8 +1075,8 @@ static int samldb_prim_group_change(struct samldb_ctx *ac) /* Fetch informations from the existing object */ - ret = ldb_search(ldb, ac, &res, ac->msg->dn, LDB_SCOPE_BASE, attrs, - NULL); + ret = dsdb_module_search(ac->module, ac, &res, ac->msg->dn, LDB_SCOPE_BASE, attrs, + DSDB_FLAG_NEXT_MODULE, ac->req, NULL); if (ret != LDB_SUCCESS) { return ret; } @@ -1432,8 +1432,9 @@ static int samldb_sam_accountname_check(struct samldb_ctx *ac) /* Make sure that a "sAMAccountName" is only used once */ - ret = ldb_search(ldb, ac, &res, NULL, LDB_SCOPE_SUBTREE, no_attrs, - "(sAMAccountName=%s)", enc_str); + ret = dsdb_module_search(ac->module, ac, &res, NULL, LDB_SCOPE_SUBTREE, no_attrs, + DSDB_FLAG_NEXT_MODULE, ac->req, + "(sAMAccountName=%s)", enc_str); if (ret != LDB_SUCCESS) { return ret; } @@ -1467,8 +1468,8 @@ static int samldb_member_check(struct samldb_ctx *ac) /* Fetch informations from the existing object */ - ret = ldb_search(ldb, ac, &res, ac->msg->dn, LDB_SCOPE_BASE, attrs, - NULL); + ret = dsdb_module_search(ac->module, ac, &res, ac->msg->dn, LDB_SCOPE_BASE, attrs, + DSDB_FLAG_NEXT_MODULE, ac->req, NULL); if (ret != LDB_SUCCESS) { return ret; } @@ -1582,8 +1583,8 @@ static int samldb_description_check(struct samldb_ctx *ac) /* Fetch informations from the existing object */ - ret = ldb_search(ldb, ac, &res, ac->msg->dn, LDB_SCOPE_BASE, attrs, - NULL); + ret = dsdb_module_search(ac->module, ac, &res, ac->msg->dn, LDB_SCOPE_BASE, attrs, + DSDB_FLAG_NEXT_MODULE, ac->req, NULL); if (ret != LDB_SUCCESS) { return ret; } @@ -1782,8 +1783,8 @@ static int samldb_service_principal_names_change(struct samldb_ctx *ac) } /* Fetch the "servicePrincipalName"s if any */ - ret = ldb_search(ldb, ac, &res, ac->msg->dn, LDB_SCOPE_BASE, attrs, - NULL); + ret = dsdb_module_search(ac->module, ac, &res, ac->msg->dn, LDB_SCOPE_BASE, attrs, + DSDB_FLAG_NEXT_MODULE, ac->req, NULL); if (ret != LDB_SUCCESS) { return ret; } |