diff options
author | Keith Bostic <keith@wiredtiger.com> | 2014-02-05 15:45:54 -0500 |
---|---|---|
committer | Keith Bostic <keith@wiredtiger.com> | 2014-02-05 15:45:54 -0500 |
commit | 4adabd868acdd540eb93b9bdafcd2394c73dc99e (patch) | |
tree | d36e65ffc598798eedf99b5657b545729e1185df /src/btree/bt_vrfy.c | |
parent | 50d9147a965c0ece7786b53d55bbe1149940136c (diff) | |
download | mongo-4adabd868acdd540eb93b9bdafcd2394c73dc99e.tar.gz |
Add a new level of indirection on internal pages so there's a way to
split them by atomically replacing the WT_REF array with a new one.
Diffstat (limited to 'src/btree/bt_vrfy.c')
-rw-r--r-- | src/btree/bt_vrfy.c | 14 |
1 files changed, 7 insertions, 7 deletions
diff --git a/src/btree/bt_vrfy.c b/src/btree/bt_vrfy.c index 421cdb79e68..574c703edf8 100644 --- a/src/btree/bt_vrfy.c +++ b/src/btree/bt_vrfy.c @@ -221,7 +221,7 @@ __verify_tree(WT_SESSION_IMPL *session, WT_PAGE *page, WT_VSTUFF *vs) WT_CELL_UNPACK *unpack, _unpack; WT_COL *cip; WT_DECL_RET; - WT_REF *ref; + WT_REF **refp, *ref; uint64_t recno; uint32_t entry, i; int found; @@ -297,7 +297,7 @@ recno_chk: if (recno != vs->record_total + 1) } switch (page->type) { case WT_PAGE_COL_FIX: - vs->record_total += page->entries; + vs->record_total += page->pu_fix_entries; break; case WT_PAGE_COL_VAR: recno = 0; @@ -389,7 +389,7 @@ celltype_err: WT_RET_MSG(session, WT_ERROR, case WT_PAGE_COL_INT: /* For each entry in an internal page, verify the subtree. */ entry = 0; - WT_REF_FOREACH(page, ref, i) { + WT_INTL_FOREACH(page, refp, ref, i) { /* * It's a depth-first traversal: this entry's starting * record number should be 1 more than the total records @@ -423,7 +423,7 @@ celltype_err: WT_RET_MSG(session, WT_ERROR, case WT_PAGE_ROW_INT: /* For each entry in an internal page, verify the subtree. */ entry = 0; - WT_REF_FOREACH(page, ref, i) { + WT_INTL_FOREACH(page, refp, ref, i) { /* * It's a depth-first traversal: this entry's starting * key should be larger than the largest key previously @@ -509,7 +509,7 @@ __verify_row_leaf_key_order( * If a tree is empty (just created), it won't have keys; if there * are no keys, we're done. */ - if (page->entries == 0) + if (page->pu_row_entries == 0) return (0); /* @@ -543,8 +543,8 @@ __verify_row_leaf_key_order( } /* Update the largest key we've seen to the last key on this page. */ - WT_RET(__wt_row_leaf_key_copy(session, - page, page->u.row.d + (page->entries - 1), vs->max_key)); + WT_RET(__wt_row_leaf_key_copy(session, page, + page->u.row.d + (page->pu_row_entries - 1), vs->max_key)); (void)__wt_page_addr_string(session, vs->max_addr, page); return (0); |