aboutsummaryrefslogtreecommitdiff
path: root/lib/libc/db/recno/rec_search.c
diff options
context:
space:
mode:
Diffstat (limited to 'lib/libc/db/recno/rec_search.c')
-rw-r--r--lib/libc/db/recno/rec_search.c14
1 files changed, 7 insertions, 7 deletions
diff --git a/lib/libc/db/recno/rec_search.c b/lib/libc/db/recno/rec_search.c
index 61bcb7509441..68e7f2d195df 100644
--- a/lib/libc/db/recno/rec_search.c
+++ b/lib/libc/db/recno/rec_search.c
@@ -61,7 +61,7 @@ __FBSDID("$FreeBSD$");
EPG *
__rec_search(BTREE *t, recno_t recno, enum SRCHOP op)
{
- indx_t index;
+ indx_t idx;
PAGE *h;
EPGNO *parent;
RINTERNAL *r;
@@ -79,23 +79,23 @@ __rec_search(BTREE *t, recno_t recno, enum SRCHOP op)
t->bt_cur.index = recno - total;
return (&t->bt_cur);
}
- for (index = 0, top = NEXTINDEX(h);;) {
- r = GETRINTERNAL(h, index);
- if (++index == top || total + r->nrecs > recno)
+ for (idx = 0, top = NEXTINDEX(h);;) {
+ r = GETRINTERNAL(h, idx);
+ if (++idx == top || total + r->nrecs > recno)
break;
total += r->nrecs;
}
- BT_PUSH(t, pg, index - 1);
+ BT_PUSH(t, pg, idx - 1);
pg = r->pgno;
switch (op) {
case SDELETE:
- --GETRINTERNAL(h, (index - 1))->nrecs;
+ --GETRINTERNAL(h, (idx - 1))->nrecs;
mpool_put(t->bt_mp, h, MPOOL_DIRTY);
break;
case SINSERT:
- ++GETRINTERNAL(h, (index - 1))->nrecs;
+ ++GETRINTERNAL(h, (idx - 1))->nrecs;
mpool_put(t->bt_mp, h, MPOOL_DIRTY);
break;
case SEARCH: