hobject_t next;
hobject_t lower_bound = response.handle;
- dout(10) << " pgnls lower_bound " << lower_bound << dendl;
+ hobject_t pg_start = info.pgid.pgid.get_hobj_start();
+ hobject_t pg_end = info.pgid.pgid.get_hobj_end(pool.info.get_pg_num());
+ dout(10) << " pgnls lower_bound " << lower_bound
+ << " pg_end " << pg_end << dendl;
+ if (get_sort_bitwise() &&
+ ((lower_bound != hobject_t::get_max() &&
+ cmp_bitwise(lower_bound, pg_end) >= 0) ||
+ (lower_bound != hobject_t() &&
+ cmp_bitwise(lower_bound, pg_start) < 0))) {
+ // this should only happen with a buggy client.
+ dout(10) << "outside of PG bounds " << pg_start << " .. "
+ << pg_end << dendl;
+ result = -EINVAL;
+ break;
+ }
hobject_t current = lower_bound;
osr->flush();