diff options
author | Keith Bostic <keith@wiredtiger.com> | 2015-08-24 12:44:05 -0400 |
---|---|---|
committer | Keith Bostic <keith@wiredtiger.com> | 2015-08-24 12:48:12 -0400 |
commit | 8969ddea9f1dc922f26206adbd5ec927fe3cb316 (patch) | |
tree | cfe51a631a3164832e9f1ba33b595a681869077d /src/block/block_read.c | |
parent | 7ff1293d2557bbf3344e49de0f2f89a4e903fb14 (diff) | |
download | mongo-8969ddea9f1dc922f26206adbd5ec927fe3cb316.tar.gz |
WT-1822, WT-2051
Rename WT_SESSION_SALVAGE_CORRUPT_OK flag to WT_SESSION_QUIET_CORRUPT_FILE,
it's no longer salvage only.
Set/clear WT_SESSION_QUIET_CORRUPT_FILE around the initial read and verify
of the root page when the file is opened so we don't output scary messages
into the MongoDB log ("item XX on page at YY is a corrupted cell").
Diffstat (limited to 'src/block/block_read.c')
-rw-r--r-- | src/block/block_read.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/src/block/block_read.c b/src/block/block_read.c index 0d631396b41..9f7c869dd38 100644 --- a/src/block/block_read.c +++ b/src/block/block_read.c @@ -200,7 +200,7 @@ __wt_block_read_off(WT_SESSION_IMPL *session, WT_BLOCK *block, if (page_cksum == cksum) return (0); - if (!F_ISSET(session, WT_SESSION_SALVAGE_CORRUPT_OK)) + if (!F_ISSET(session, WT_SESSION_QUIET_CORRUPT_FILE)) __wt_errx(session, "read checksum error for %" PRIu32 "B block at " "offset %" PRIuMAX ": calculated block checksum " @@ -208,7 +208,7 @@ __wt_block_read_off(WT_SESSION_IMPL *session, WT_BLOCK *block, "of %" PRIu32, size, (uintmax_t)offset, page_cksum, cksum); } else - if (!F_ISSET(session, WT_SESSION_SALVAGE_CORRUPT_OK)) + if (!F_ISSET(session, WT_SESSION_QUIET_CORRUPT_FILE)) __wt_errx(session, "read checksum error for %" PRIu32 "B block at " "offset %" PRIuMAX ": block header checksum " @@ -218,6 +218,6 @@ __wt_block_read_off(WT_SESSION_IMPL *session, WT_BLOCK *block, /* Panic if a checksum fails during an ordinary read. */ return (block->verify || - F_ISSET(session, WT_SESSION_SALVAGE_CORRUPT_OK) ? + F_ISSET(session, WT_SESSION_QUIET_CORRUPT_FILE) ? WT_ERROR : __wt_illegal_value(session, block->name)); } |