WriteUnPrepared: Pass snap_released to the callback (#5691)

Summary:
With changes made in https://github.com/facebook/rocksdb/pull/5664 we meant to pass snap_released parameter of ::IsInSnapshot from the read callbacks. Although the variable was defined, passing it to the callback in WritePreparedTxnReadCallback was missing, which is fixed in this PR.
Pull Request resolved: https://github.com/facebook/rocksdb/pull/5691

Differential Revision: D16767310

Pulled By: maysamyabandeh

fbshipit-source-id: 3bf53f5964a2756a66ceef7c8f6b3ac75f102f48
This commit is contained in:
Maysam Yabandeh 2019-08-12 12:17:26 -07:00 committed by Facebook Github Bot
parent 6f0f82de87
commit 64855979ae

View File

@ -26,7 +26,8 @@ bool WriteUnpreparedTxnReadCallback::IsVisibleFullCheck(SequenceNumber seq) {
} }
bool snap_released = false; bool snap_released = false;
auto ret = db_->IsInSnapshot(seq, wup_snapshot_, min_uncommitted_); auto ret =
db_->IsInSnapshot(seq, wup_snapshot_, min_uncommitted_, &snap_released);
assert(!snap_released || backed_by_snapshot_ == kUnbackedByDBSnapshot); assert(!snap_released || backed_by_snapshot_ == kUnbackedByDBSnapshot);
snap_released_ |= snap_released; snap_released_ |= snap_released;
return ret; return ret;