From: Mark Kogan Date: Mon, 26 Apr 2021 12:36:08 +0000 (+0300) Subject: rgw: fix segfault related to explicit object manifest handling X-Git-Tag: v17.1.0~2114^2 X-Git-Url: http://git-server-git.apps.pok.os.sepia.ceph.com/?a=commitdiff_plain;h=ae00453515b17d25a5d42430e744855b020ccec6;p=ceph.git rgw: fix segfault related to explicit object manifest handling Fixes: https://tracker.ceph.com/issues/50467 Signed-off-by: Mark Kogan --- diff --git a/src/rgw/rgw_obj_manifest.cc b/src/rgw/rgw_obj_manifest.cc index e1fcc3af979..7e5a4ec80af 100644 --- a/src/rgw/rgw_obj_manifest.cc +++ b/src/rgw/rgw_obj_manifest.cc @@ -226,6 +226,12 @@ void RGWObjManifest::obj_iterator::operator++() if (manifest->explicit_objs) { ++explicit_iter; + if (explicit_iter == manifest->objs.end()) { + ofs = manifest->obj_size; + stripe_size = 0; + return; + } + update_explicit_pos(); update_location();