sizeof(indx_t) when computing space used in a page by an item.
[patch from www.sleepycat.com]
git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@14780
dc483132-0cff-0310-8789-
dd5450dbe970
+2002-08-28 Tom Yu <tlyu@mit.edu>
+
+ * btree/bt_split.c (bt_psplit): Correctly account for
+ sizeof(indx_t) when computing space used in a page by an item.
+ [patch from www.sleepycat.com]
+
2002-08-23 Ken Raeburn <raeburn@mit.edu>
* Makefile.in, btree/Makefile.in, clib/Makefile.in,
* where we decide to try and copy too much onto the left page.
* Make sure that doesn't happen.
*/
- if ((skip <= off && used + nbytes >= full) || nxt == top - 1) {
+ if ((skip <= off && used + nbytes + sizeof(indx_t) >= full)
+ || nxt == top - 1) {
--off;
break;
}
memmove((char *)l + l->upper, src, nbytes);
}
- used += nbytes;
+ used += nbytes + sizeof(indx_t);
if (used >= half) {
if (!isbigkey || bigkeycnt == 3)
break;