Skip to content

Commit

Permalink
Add db_test2 to to ASSERT_STATUS_CHECKED (facebook#8640)
Browse files Browse the repository at this point in the history
Summary:
This is the `db_test2` parts of facebook#7737 reworked on the latest HEAD.

Pull Request resolved: facebook#8640

Reviewed By: akankshamahajan15

Differential Revision: D30303684

Pulled By: mrambacher

fbshipit-source-id: 263e2f82d849bde4048b60aed8b31e7deed4706a
  • Loading branch information
adamretter authored and facebook-github-bot committed Aug 16, 2021
1 parent 9b0a32f commit 5de333f
Show file tree
Hide file tree
Showing 7 changed files with 282 additions and 196 deletions.
1 change: 0 additions & 1 deletion Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -525,7 +525,6 @@ ifdef ASSERT_STATUS_CHECKED
TESTS_FAILING_ASC = \
c_test \
db_test \
db_test2 \
env_test \
range_locking_test \
testutil_test \
Expand Down
2 changes: 1 addition & 1 deletion db/db_impl/db_impl.cc
Original file line number Diff line number Diff line change
Expand Up @@ -5103,7 +5103,7 @@ Status DBImpl::EndTrace() {
s = tracer_->Close();
tracer_.reset();
} else {
return Status::IOError("No trace file to close");
s = Status::IOError("No trace file to close");
}
return s;
}
Expand Down
6 changes: 4 additions & 2 deletions db/db_impl/db_impl_open.cc
Original file line number Diff line number Diff line change
Expand Up @@ -1434,8 +1434,10 @@ Status DBImpl::WriteLevel0TableForRecovery(int job_id, ColumnFamilyData* cfd,
meta.fd.GetFileSize(), s.ToString().c_str());
mutex_.Lock();

io_s.PermitUncheckedError(); // TODO(AR) is this correct, or should we
// return io_s if not ok()?
// TODO(AR) is this ok?
if (!io_s.ok() && s.ok()) {
s = io_s;
}
}
}
ReleaseFileNumberFromPendingOutputs(pending_outputs_inserted_elem);
Expand Down
Loading

0 comments on commit 5de333f

Please sign in to comment.