From: Yehuda Sadeh Date: Wed, 26 Aug 2015 21:34:30 +0000 (-0700) Subject: rgw: init some manifest fields when handling explicit objs X-Git-Tag: v9.1.0~271^2~1^2 X-Git-Url: http://git-server-git.apps.pok.os.sepia.ceph.com/?a=commitdiff_plain;h=d7bf8cb594e5276d1c80544f5ec954d52b159750;p=ceph.git rgw: init some manifest fields when handling explicit objs Fixes: #11455 When dealing with old manifest that has explicit objs, we also need to set the head size and head object correctly so that code that relies on this info doesn't break. Signed-off-by: Yehuda Sadeh --- diff --git a/src/rgw/rgw_rados.h b/src/rgw/rgw_rados.h index 25caf2ca123..9d5de6df916 100644 --- a/src/rgw/rgw_rados.h +++ b/src/rgw/rgw_rados.h @@ -327,6 +327,12 @@ public: ::decode(rules, bl); } else { explicit_objs = true; + if (!objs.empty()) { + map::iterator iter = objs.begin(); + head_obj = iter->second.loc; + head_size = iter->second.size; + max_head_size = head_size; + } } if (struct_v >= 4) {