If `get_bucket_index_object` returns an error code (-ENOTSUP)
with ivalid `hash_type`, we should return this negative error code
that resulting in `BucketShard::init` failed as expected,
oherwise it will go wrong.
Signed-off-by: Yan Jun <yan.jun8@zte.com.cn>
(RGWBucketInfo::BIShardsHashType)binfo.bucket_index_shard_hash_type, bucket_obj, shard_id);
if (ret < 0) {
ldout(cct, 10) << "get_bucket_index_object() returned ret=" << ret << dendl;
+ return ret;
}
return 0;
}