s4:partition: register DOMAIN_SCOPE and SEARCH_OPTIONS controls
authorStefan Metzmacher <metze@samba.org>
Thu, 2 Oct 2008 09:22:33 +0000 (11:22 +0200)
committerStefan Metzmacher <metze@samba.org>
Thu, 2 Oct 2008 10:20:58 +0000 (12:20 +0200)
metze

source4/dsdb/samdb/ldb_modules/partition.c

index ad3518e6b2ec61acf7e3374b9df75fb2f79862e2..f600c727484362ca159ea32da36bc57f4576ce5a 100644 (file)
@@ -1160,6 +1160,20 @@ static int partition_init(struct ldb_module *module)
                }
        }
 
+       ret = ldb_mod_register_control(module, LDB_CONTROL_DOMAIN_SCOPE_OID);
+       if (ret != LDB_SUCCESS) {
+               ldb_debug(module->ldb, LDB_DEBUG_ERROR,
+                       "partition: Unable to register control with rootdse!\n");
+               return LDB_ERR_OPERATIONS_ERROR;
+       }
+
+       ret = ldb_mod_register_control(module, LDB_CONTROL_SEARCH_OPTIONS_OID);
+       if (ret != LDB_SUCCESS) {
+               ldb_debug(module->ldb, LDB_DEBUG_ERROR,
+                       "partition: Unable to register control with rootdse!\n");
+               return LDB_ERR_OPERATIONS_ERROR;
+       }
+
        talloc_free(mem_ctx);
        return ldb_next_init(module);
 }