[RocksDB] Fix FindMinimumEmptyLevelFitting

Summary: as title

Test Plan: make check;

Reviewers: xjin

CC: leveldb

Differential Revision: https://reviews.facebook.net/D11751
main
Haobo Xu 12 years ago
parent 9ee68871dc
commit d364eea1fc
  1. 2
      db/db_impl.cc

@ -928,7 +928,7 @@ void DBImpl::CompactRange(const Slice* begin, const Slice* end,
int DBImpl::FindMinimumEmptyLevelFitting(int level) {
mutex_.AssertHeld();
int minimum_level = level;
for (int i = level - 1; i > 0; ++i) {
for (int i = level - 1; i > 0; --i) {
// stop if level i is not empty
if (versions_->NumLevelFiles(i) > 0) break;

Loading…
Cancel
Save