On Sun, Nov 24, 2019 at 9:58 AM Ranier Vilela <ranier_...@hotmail.com> wrote: > Within the function _bt_afternewitemoff, at line 641, maxoff is used in an > dangerous expression, > without protection.: (maxoff - 1)
I wrote this code. It's safe. In general, it's not possible to split a page without it being initialized, and having at least 2 items (not including the incoming newitem). Besides, even if "maxoff" had an integer underflow the behavior of the function would still be sane and defined. OffsetNumber is an unsigned type. Where are you getting this stuff from? Are you using a static analysis tool? -- Peter Geoghegan