Fix bug introduced into _bt_getstackbuf() on 2003-Feb-21: the initial
authorTom Lane <tgl@sss.pgh.pa.us>
Tue, 17 Aug 2004 23:16:07 +0000 (23:16 +0000)
committerTom Lane <tgl@sss.pgh.pa.us>
Tue, 17 Aug 2004 23:16:07 +0000 (23:16 +0000)
commit25a9561acf24bc15545d7835adb44bec2c82ceac
treec075001831b5e41ffea9a9e394cf535ae8fe967c
parentef6630c7fc1d7b269f25c57d7df0dc276eabe8b7
Fix bug introduced into _bt_getstackbuf() on 2003-Feb-21: the initial
value of 'start' could be past the end of the page, if the page was
split by some concurrent inserting process since we visited it.  In
this situation the code could look at bogus entries and possibly find
a match (since after all those entries still contain what they had
before the split).  This would lead to 'specified item offset is too large'
followed by 'PANIC: failed to add item to the page', as reported by Joe
Conway for scenarios involving heavy concurrent insertion activity.
src/backend/access/nbtree/nbtinsert.c