Fix TEST_Destroy_DBImpl() to work with column families

This commit is contained in:
Igor Canadi 2014-03-05 12:27:39 -08:00
parent 0738ae6dc9
commit a329dd1b25

View File

@ -361,6 +361,10 @@ void DBImpl::TEST_Destroy_DBImpl() {
bg_compaction_scheduled_ += LargeNumber;
mutex_.Unlock();
if (default_cf_handle_ != nullptr) {
// we need to delete handle outside of lock because it does its own locking
delete default_cf_handle_;
}
LogFlush(options_.info_log);
// force release the lock file.
@ -369,7 +373,9 @@ void DBImpl::TEST_Destroy_DBImpl() {
}
log_.reset();
mutex_.Lock();
versions_.reset();
mutex_.Unlock();
table_cache_.reset();
}