struct composite_context *c = s->creq;
struct rpc_request *req;
struct drsuapi_DsGetNCChanges *r;
+ int32_t level;
r = talloc(s, struct drsuapi_DsGetNCChanges);
if (composite_nomem(r, c)) return;
+ r->in.level = &level;
r->in.bind_handle = &drsuapi_h->bind_handle;
if (drsuapi_h->remote_info28.supported_extensions & DRSUAPI_SUPPORTED_EXTENSION_GETCHGREQ_V8) {
- r->in.level = 8;
+ level = 8;
r->in.req.req8.destination_dsa_guid = partition->destination_dsa_guid;
r->in.req.req8.source_dsa_invocation_id = partition->source_dsa_invocation_id;
r->in.req.req8.naming_context = &partition->nc;
r->in.req.req8.mapping_ctr.num_mappings = 0;
r->in.req.req8.mapping_ctr.mappings = NULL;
} else {
- r->in.level = 5;
+ level = 5;
r->in.req.req5.destination_dsa_guid = partition->destination_dsa_guid;
r->in.req.req5.source_dsa_invocation_id = partition->source_dsa_invocation_id;
r->in.req.req5.naming_context = &partition->nc;
return r->out.result;
}
- if (r->out.level == 1) {
+ if (*r->out.level == 1) {
ctr_level = 1;
ctr1 = &r->out.ctr.ctr1;
- } else if (r->out.level == 2) {
+ } else if (*r->out.level == 2) {
ctr_level = 1;
ctr1 = r->out.ctr.ctr2.ctr.mszip1.ctr1;
- } else if (r->out.level == 6) {
+ } else if (*r->out.level == 6) {
ctr_level = 6;
ctr6 = &r->out.ctr.ctr6;
- } else if (r->out.level == 7 &&
+ } else if (*r->out.level == 7 &&
r->out.ctr.ctr7.level == 6 &&
r->out.ctr.ctr7.type == DRSUAPI_COMPRESSION_TYPE_MSZIP) {
ctr_level = 6;
WERROR drsuapi_DsGetNCChanges(
[in] policy_handle *bind_handle,
- [in,out] int32 level,
- [in,switch_is(level)] drsuapi_DsGetNCChangesRequest req,
- [out,switch_is(level)] drsuapi_DsGetNCChangesCtr ctr
+ [in,out,ref] int32 *level,
+ [in,switch_is(*level)] drsuapi_DsGetNCChangesRequest req,
+ [out,switch_is(*level)] drsuapi_DsGetNCChangesCtr ctr
);
/*****************/
array[i].level);
r.in.bind_handle = &priv->bind_handle;
- r.in.level = array[i].level;
+ r.in.level = &array[i].level;
- switch (r.in.level) {
+ switch (*r.in.level) {
case 5:
nc.guid = null_guid;
nc.sid = null_sid;
array[i].level);
r.in.bind_handle = &ctx->new_dc.drsuapi.bind_handle;
- r.in.level = array[i].level;
+ r.in.level = &array[i].level;
- switch (r.in.level) {
+ switch (*r.in.level) {
case 5:
nc.guid = null_guid;
nc.sid = null_sid;
for (y=0; ;y++) {
ZERO_STRUCT(r.out);
- if (r.in.level == 5) {
+ if (*r.in.level == 5) {
DEBUG(0,("start[%d] tmp_higest_usn: %llu , highest_usn: %llu\n",y,
(long long)r.in.req.req5.highwatermark.tmp_highest_usn,
(long long)r.in.req.req5.highwatermark.highest_usn));
}
- if (r.in.level == 8) {
+ if (*r.in.level == 8) {
DEBUG(0,("start[%d] tmp_higest_usn: %llu , highest_usn: %llu\n",y,
(long long)r.in.req.req8.highwatermark.tmp_highest_usn,
(long long)r.in.req.req8.highwatermark.highest_usn));
ret = False;
}
- if (ret == True && r.out.level == 1) {
+ if (ret == True && *r.out.level == 1) {
out_level = 1;
ctr1 = &r.out.ctr.ctr1;
- } else if (ret == True && r.out.level == 2) {
+ } else if (ret == True && *r.out.level == 2) {
out_level = 1;
ctr1 = r.out.ctr.ctr2.ctr.mszip1.ctr1;
}
}
}
- if (ret == True && r.out.level == 6) {
+ if (ret == True && *r.out.level == 6) {
out_level = 6;
ctr6 = &r.out.ctr.ctr6;
- } else if (ret == True && r.out.level == 7
+ } else if (ret == True && *r.out.level == 7
&& r.out.ctr.ctr7.level == 6
&& r.out.ctr.ctr7.type == DRSUAPI_COMPRESSION_TYPE_MSZIP) {
out_level = 6;