diff options
author | MarcoFalke <falke.marco@gmail.com> | 2018-02-16 09:01:35 -0500 |
---|---|---|
committer | MarcoFalke <falke.marco@gmail.com> | 2018-02-16 08:59:28 -0500 |
commit | faa6dd27b1f1f96f5e1a26e830e1a80255afdb5f (patch) | |
tree | ac28ac960c3a60cfa750bf86d095ef01e0f72280 /src/leveldb/db | |
parent | 13e31dd6548d64a5992f439e74bb424bf88aca04 (diff) | |
parent | 835a21b42402d546bd72f8a3f452f0c743fefe82 (diff) |
Bump leveldb subtree
Diffstat (limited to 'src/leveldb/db')
-rw-r--r-- | src/leveldb/db/db_impl.cc | 2 | ||||
-rw-r--r-- | src/leveldb/db/leveldbutil.cc | 1 | ||||
-rw-r--r-- | src/leveldb/db/log_reader.cc | 2 | ||||
-rw-r--r-- | src/leveldb/db/repair.cc | 2 |
4 files changed, 4 insertions, 3 deletions
diff --git a/src/leveldb/db/db_impl.cc b/src/leveldb/db/db_impl.cc index f43ad76794..3bb58e560a 100644 --- a/src/leveldb/db/db_impl.cc +++ b/src/leveldb/db/db_impl.cc @@ -414,7 +414,7 @@ Status DBImpl::RecoverLogFile(uint64_t log_number, bool last_log, status.ok()) { if (record.size() < 12) { reporter.Corruption( - record.size(), Status::Corruption("log record too small")); + record.size(), Status::Corruption("log record too small", fname)); continue; } WriteBatchInternal::SetContents(&batch, record); diff --git a/src/leveldb/db/leveldbutil.cc b/src/leveldb/db/leveldbutil.cc index 9f4b7dd70c..d06d64d640 100644 --- a/src/leveldb/db/leveldbutil.cc +++ b/src/leveldb/db/leveldbutil.cc @@ -19,6 +19,7 @@ class StdoutPrinter : public WritableFile { virtual Status Close() { return Status::OK(); } virtual Status Flush() { return Status::OK(); } virtual Status Sync() { return Status::OK(); } + virtual std::string GetName() const { return "[stdout]"; } }; bool HandleDumpCommand(Env* env, char** files, int num) { diff --git a/src/leveldb/db/log_reader.cc b/src/leveldb/db/log_reader.cc index a6d304545d..8b6ad136d7 100644 --- a/src/leveldb/db/log_reader.cc +++ b/src/leveldb/db/log_reader.cc @@ -186,7 +186,7 @@ uint64_t Reader::LastRecordOffset() { } void Reader::ReportCorruption(uint64_t bytes, const char* reason) { - ReportDrop(bytes, Status::Corruption(reason)); + ReportDrop(bytes, Status::Corruption(reason, file_->GetName())); } void Reader::ReportDrop(uint64_t bytes, const Status& reason) { diff --git a/src/leveldb/db/repair.cc b/src/leveldb/db/repair.cc index 4cd4bb047f..7281e3d345 100644 --- a/src/leveldb/db/repair.cc +++ b/src/leveldb/db/repair.cc @@ -203,7 +203,7 @@ class Repairer { while (reader.ReadRecord(&record, &scratch)) { if (record.size() < 12) { reporter.Corruption( - record.size(), Status::Corruption("log record too small")); + record.size(), Status::Corruption("log record too small", logname)); continue; } WriteBatchInternal::SetContents(&batch, record); |