summaryrefslogtreecommitdiff
path: root/src/reconcile
diff options
context:
space:
mode:
authorKeith Bostic <keith@wiredtiger.com>2016-04-23 10:16:18 -0400
committerKeith Bostic <keith@wiredtiger.com>2016-04-23 10:16:18 -0400
commitd913f628d3616e54c44b8df6b674d8d7bda890b8 (patch)
treeb861460aed606ff6ab8698227fba91369d2f0dd6 /src/reconcile
parenteb4a2ff50e7aab03405f068ee8dfa82bd0c51bcb (diff)
downloadmongo-d913f628d3616e54c44b8df6b674d8d7bda890b8.tar.gz
WT-2581: assert multi->disk_image == NULL
Simplify the logic slightly, there's no reason to mess around with the address references, we're about to free that memory.
Diffstat (limited to 'src/reconcile')
-rw-r--r--src/reconcile/rec_write.c6
1 files changed, 2 insertions, 4 deletions
diff --git a/src/reconcile/rec_write.c b/src/reconcile/rec_write.c
index 318a38255c0..a46662b4b9d 100644
--- a/src/reconcile/rec_write.c
+++ b/src/reconcile/rec_write.c
@@ -5466,13 +5466,11 @@ __rec_split_discard(WT_SESSION_IMPL *session, WT_PAGE *page)
* write). The page may instead have been a disk image with
* associated saved updates: ownership of the disk image is
* transferred when rewriting the page in-memory and there may
- * not have been saved updaates. We've gotten this wrong a few
+ * not have been saved updates. We've gotten this wrong a few
* times, so use the existence of an address to confirm backing
* blocks we care about, and free any disk image/saved updates.
*/
- if (multi->addr.addr != NULL && multi->addr.reuse)
- multi->addr.addr = NULL;
- if (multi->addr.addr != NULL) {
+ if (multi->addr.addr != NULL && !multi->addr.reuse) {
WT_RET(__wt_btree_block_free(
session, multi->addr.addr, multi->addr.size));
__wt_free(session, multi->addr.addr);