diff options
author | Michael Cahill <michael.cahill@wiredtiger.com> | 2012-01-23 22:32:28 +1100 |
---|---|---|
committer | Michael Cahill <michael.cahill@wiredtiger.com> | 2012-01-23 22:32:28 +1100 |
commit | 1b06bf34bbeb8a5f27e6b320c0929a7f33dc4b36 (patch) | |
tree | fcc8aca611883d11cf6872c6d770e2f953fde39e /src/bdb | |
parent | 80deca72baafe78dabfff58c7ecd8dc089219460 (diff) | |
download | mongo-1b06bf34bbeb8a5f27e6b320c0929a7f33dc4b36.tar.gz |
Some cleanup of the hazard code. In particular:
* error handling: use of WT_RET in functions that are only expected to return a boolean (e.g., WT_REF(__wt_realloc(...)) in __hazard_exclusive.
Switch to zero for success and EBUSY if the page is already locked. This shouldn't make it out to applications but at least is from the same namespace as ENOMEM or other system errors.
* two threads calling __hazard_exclusive concurrently were sharing memory in cache->hazard, with unpredictable results.
* the WT_REF_LOCKED state was being used for multiple things. Add a WT_REF_EVICTING state to prevent multiple threads choosing the same page from the eviction queue.
Diffstat (limited to 'src/bdb')
0 files changed, 0 insertions, 0 deletions