summaryrefslogtreecommitdiff
path: root/source4
diff options
context:
space:
mode:
authorStefan Metzmacher <metze@samba.org>2007-01-11 10:21:38 +0000
committerGerald (Jerry) Carter <jerry@samba.org>2007-10-10 14:40:21 -0500
commitfbba1b39d47224feed48f904c59221008c3bf090 (patch)
tree28b78e6da8c7103fbbe70527f728ae4e7b1efd33 /source4
parentf68dff9f81afc8b107ad41d5b446f33ecdc2fcb1 (diff)
downloadsamba-fbba1b39d47224feed48f904c59221008c3bf090.tar.gz
samba-fbba1b39d47224feed48f904c59221008c3bf090.tar.bz2
samba-fbba1b39d47224feed48f904c59221008c3bf090.zip
r20682: make the dsdb_extended_replicated_objects_commit() interface a bit more useful,
so that we can apply the schema partition objects with one call metze (This used to be commit 165ff94b8a89ef4b9145405633ed11ab9567376b)
Diffstat (limited to 'source4')
-rw-r--r--source4/dsdb/repl/replicated_objects.c30
-rw-r--r--source4/dsdb/samdb/samdb.h25
2 files changed, 18 insertions, 37 deletions
diff --git a/source4/dsdb/repl/replicated_objects.c b/source4/dsdb/repl/replicated_objects.c
index 3a914c6774..0ccb46b9c8 100644
--- a/source4/dsdb/repl/replicated_objects.c
+++ b/source4/dsdb/repl/replicated_objects.c
@@ -178,37 +178,23 @@ static WERROR dsdb_convert_object(struct ldb_context *ldb,
WERROR dsdb_extended_replicated_objects_commit(struct ldb_context *ldb,
const char *partition_dn,
const struct dsdb_schema *schema,
- uint32_t ctr_level,
- const struct drsuapi_DsGetNCChangesCtr1 *ctr1,
- const struct drsuapi_DsGetNCChangesCtr6 *ctr6,
+ const struct drsuapi_DsReplicaOIDMapping_Ctr *mapping_ctr,
+ uint32_t object_count,
+ const struct drsuapi_DsReplicaObjectListItemEx *first_object,
+ uint32_t linked_attributes_count,
+ const struct drsuapi_DsReplicaLinkedAttribute *linked_attributes,
+ const struct drsuapi_DsReplicaHighWaterMark *new_highwatermark,
+ const struct drsuapi_DsReplicaCursor2CtrEx *uptodateness_vector,
TALLOC_CTX *mem_ctx,
struct dsdb_extended_replicated_objects **_out)
{
WERROR status;
struct dsdb_extended_replicated_objects *out;
struct ldb_result *ext_res;
- const struct drsuapi_DsReplicaOIDMapping_Ctr *mapping_ctr;
- uint32_t object_count;
- struct drsuapi_DsReplicaObjectListItemEx *first_object;
- struct drsuapi_DsReplicaObjectListItemEx *cur;
+ const struct drsuapi_DsReplicaObjectListItemEx *cur;
uint32_t i;
int ret;
- switch (ctr_level) {
- case 1:
- mapping_ctr = &ctr1->mapping_ctr;
- object_count = ctr1->object_count;
- first_object = ctr1->first_object;
- break;
- case 6:
- mapping_ctr = &ctr6->mapping_ctr;
- object_count = ctr6->object_count;
- first_object = ctr6->first_object;
- break;
- default:
- return WERR_INVALID_PARAM;
- }
-
status = dsdb_verify_oid_mappings(schema, mapping_ctr);
W_ERROR_NOT_OK_RETURN(status);
diff --git a/source4/dsdb/samdb/samdb.h b/source4/dsdb/samdb/samdb.h
index 2387852be8..14577400ba 100644
--- a/source4/dsdb/samdb/samdb.h
+++ b/source4/dsdb/samdb/samdb.h
@@ -24,15 +24,16 @@
#define __SAMDB_H__
struct auth_session_info;
-struct drsuapi_DsNameInfo1;
-struct drsuapi_DsReplicaObject;
-struct drsuapi_DsReplicaOIDMapping_Ctr;
-struct drsuapi_DsReplicaAttribute;
-struct drsuapi_DsGetNCChangesCtr1;
-struct drsuapi_DsGetNCChangesCtr6;
-struct replPropertyMetaDataBlob;
-struct ldb_dn;
-struct ldb_message;
+struct dsdb_extended_replicated_object;
+struct dsdb_extended_replicated_objects;
+
+#include "librpc/gen_ndr/security.h"
+#include "lib/ldb/include/ldb.h"
+#include "librpc/gen_ndr/samr.h"
+#include "librpc/gen_ndr/drsuapi.h"
+#include "librpc/gen_ndr/drsblobs.h"
+#include "dsdb/schema/schema.h"
+#include "dsdb/samdb/samdb_proto.h"
#define DSDB_CONTROL_REPLICATED_OBJECT_OID "1.3.6.1.4.1.7165.4.3.1"
struct dsdb_control_replicated_object {
@@ -53,10 +54,4 @@ struct dsdb_extended_replicated_objects {
struct dsdb_extended_replicated_object *objects;
};
-#include "librpc/gen_ndr/security.h"
-#include "lib/ldb/include/ldb.h"
-#include "librpc/gen_ndr/samr.h"
-#include "dsdb/schema/schema.h"
-#include "dsdb/samdb/samdb_proto.h"
-
#endif /* __SAMDB_H__ */