rgw_read_bucket_inc_sync_status() uses the size of this vector as the
'num_shards', so we need to resize it appropriately beforehand
Signed-off-by: Casey Bodley <cbodley@redhat.com>
}
std::vector<rgw_bucket_shard_sync_info> status;
+ status.resize(full_status.shards_done_with_gen.size());
r = rgw_read_bucket_inc_sync_status(dpp, store, pipe, bucket_info, &source_bucket->get_info(), full_status.incremental_gen, &status);
if (r < 0) {
lderr(store->ctx()) << "failed to read bucket incremental sync status: " << cpp_strerror(r) << dendl;
ldpp_dout(this, -1) << "ERROR: rgw_read_bucket_full_sync_status() on pipe=" << pipe << " returned ret=" << op_ret << dendl;
return;
}
+ status.inc_status.resize(status.sync_status.shards_done_with_gen.size());
op_ret = rgw_read_bucket_inc_sync_status(
this,
return;
}
+ current_status.resize(status.sync_status.shards_done_with_gen.size());
int r = rgw_read_bucket_inc_sync_status(this, static_cast<rgw::sal::RadosStore*>(store),
pipe, *pinfo, &bucket->get_info(), status.sync_status.incremental_gen, ¤t_status);
if (r < 0) {