diff options
author | Stefan Metzmacher <metze@samba.org> | 2008-07-16 13:01:56 +0200 |
---|---|---|
committer | Stefan Metzmacher <metze@samba.org> | 2008-07-16 14:42:11 +0200 |
commit | f0e44c35afce5ceec5d247dbd4205301251e403c (patch) | |
tree | 2e0e3510aaed9e63bca5945d9f6a19111a2a54e7 /source4/libnet | |
parent | f3fae86549ee0ea6cef5cee27af7bb53e7963d7b (diff) | |
download | samba-f0e44c35afce5ceec5d247dbd4205301251e403c.tar.gz samba-f0e44c35afce5ceec5d247dbd4205301251e403c.tar.bz2 samba-f0e44c35afce5ceec5d247dbd4205301251e403c.zip |
drsuapi: make use of the 'more_data' field in DsGetNCChangesCtr[1|6]
metze
(This used to be commit 35c7fa470a7433d081403b2b57a331c7dc287aef)
Diffstat (limited to 'source4/libnet')
-rw-r--r-- | source4/libnet/libnet_become_dc.c | 10 | ||||
-rw-r--r-- | source4/libnet/libnet_become_dc.h | 1 | ||||
-rw-r--r-- | source4/libnet/libnet_vampire.c | 2 |
3 files changed, 9 insertions, 4 deletions
diff --git a/source4/libnet/libnet_become_dc.c b/source4/libnet/libnet_become_dc.c index 1f7444062a..3fece1a9ba 100644 --- a/source4/libnet/libnet_become_dc.c +++ b/source4/libnet/libnet_become_dc.c @@ -2434,6 +2434,7 @@ static WERROR becomeDC_drsuapi_pull_partition_recv(struct libnet_BecomeDC_state struct GUID *source_dsa_guid; struct GUID *source_dsa_invocation_id; struct drsuapi_DsReplicaHighWaterMark *new_highwatermark; + bool more_data = false; NTSTATUS nt_status; if (!W_ERROR_IS_OK(r->out.result)) { @@ -2474,17 +2475,20 @@ static WERROR becomeDC_drsuapi_pull_partition_recv(struct libnet_BecomeDC_state source_dsa_guid = &ctr1->source_dsa_guid; source_dsa_invocation_id = &ctr1->source_dsa_invocation_id; new_highwatermark = &ctr1->new_highwatermark; + more_data = ctr1->more_data; break; case 6: source_dsa_guid = &ctr6->source_dsa_guid; source_dsa_invocation_id = &ctr6->source_dsa_invocation_id; new_highwatermark = &ctr6->new_highwatermark; + more_data = ctr6->more_data; break; } partition->highwatermark = *new_highwatermark; partition->source_dsa_guid = *source_dsa_guid; partition->source_dsa_invocation_id = *source_dsa_invocation_id; + partition->more_data = more_data; if (!partition->store_chunk) return WERR_OK; @@ -2565,7 +2569,7 @@ static void becomeDC_drsuapi3_pull_schema_recv(struct rpc_request *req) talloc_free(r); - if (s->schema_part.highwatermark.tmp_highest_usn > s->schema_part.highwatermark.highest_usn) { + if (s->schema_part.more_data) { becomeDC_drsuapi_pull_partition_send(s, &s->drsuapi2, &s->drsuapi3, &s->schema_part, becomeDC_drsuapi3_pull_schema_recv); return; @@ -2627,7 +2631,7 @@ static void becomeDC_drsuapi3_pull_config_recv(struct rpc_request *req) talloc_free(r); - if (s->config_part.highwatermark.tmp_highest_usn > s->config_part.highwatermark.highest_usn) { + if (s->config_part.more_data) { becomeDC_drsuapi_pull_partition_send(s, &s->drsuapi2, &s->drsuapi3, &s->config_part, becomeDC_drsuapi3_pull_config_recv); return; @@ -2694,7 +2698,7 @@ static void becomeDC_drsuapi3_pull_domain_recv(struct rpc_request *req) talloc_free(r); - if (s->domain_part.highwatermark.tmp_highest_usn > s->domain_part.highwatermark.highest_usn) { + if (s->domain_part.more_data) { becomeDC_drsuapi_pull_partition_send(s, &s->drsuapi2, &s->drsuapi3, &s->domain_part, becomeDC_drsuapi3_pull_domain_recv); return; diff --git a/source4/libnet/libnet_become_dc.h b/source4/libnet/libnet_become_dc.h index 47b2896713..58fc4dc15d 100644 --- a/source4/libnet/libnet_become_dc.h +++ b/source4/libnet/libnet_become_dc.h @@ -94,6 +94,7 @@ struct libnet_BecomeDC_Partition { struct GUID source_dsa_guid; struct GUID source_dsa_invocation_id; struct drsuapi_DsReplicaHighWaterMark highwatermark; + bool more_data; uint32_t replica_flags; NTSTATUS (*store_chunk)(void *private_data, diff --git a/source4/libnet/libnet_vampire.c b/source4/libnet/libnet_vampire.c index c9975c8a29..fed57dbdcf 100644 --- a/source4/libnet/libnet_vampire.c +++ b/source4/libnet/libnet_vampire.c @@ -426,7 +426,7 @@ static NTSTATUS vampire_schema_chunk(void *private_data, for (cur = first_object; cur->next_object; cur = cur->next_object) {} s->schema_part.last_object = cur; - if (c->partition->highwatermark.tmp_highest_usn == c->partition->highwatermark.highest_usn) { + if (!c->partition->more_data) { return vampire_apply_schema(s, c); } |