From: Orit Wasserman Date: Tue, 1 May 2018 15:41:29 +0000 (+0300) Subject: rgw: fix bi_list to return max entries not max-1 X-Git-Tag: v14.0.1~965^2~1 X-Git-Url: http://git-server-git.apps.pok.os.sepia.ceph.com/?a=commitdiff_plain;h=fc44655b80d818a179a9ce6bf4aa52df13c98fc1;p=ceph.git rgw: fix bi_list to return max entries not max-1 Fixes: http://tracker.ceph.com/issues/24483 Signed-off-by: Orit Wasserman --- diff --git a/src/cls/rgw/cls_rgw.cc b/src/cls/rgw/cls_rgw.cc index bb8876cf8a4..911f8803c0c 100644 --- a/src/cls/rgw/cls_rgw.cc +++ b/src/cls/rgw/cls_rgw.cc @@ -2551,7 +2551,7 @@ static int rgw_bi_list_op(cls_method_context_t hctx, bufferlist *in, bufferlist } op_ret.is_truncated = (count >= max) || more; - while (count >= max) { + while (count > max) { op_ret.entries.pop_back(); count--; }