Fix the status overwrite
This commit is contained in:
parent
931b7f6785
commit
e89f9ef839
@ -1,5 +1,7 @@
|
|||||||
# Rocksdb Change Log
|
# Rocksdb Change Log
|
||||||
## Unreleased
|
## Unreleased
|
||||||
|
### Bug Fixes
|
||||||
|
* Fix a bug caused by overwrite the status with io status in block based table builder when writing data blocks. If status stores the error message (e.g., failure of verify block compression), the bug will make the io status overwrite the status.
|
||||||
|
|
||||||
## 6.9.3 (04/28/2020)
|
## 6.9.3 (04/28/2020)
|
||||||
### Bug Fixes
|
### Bug Fixes
|
||||||
|
@ -788,7 +788,9 @@ void BlockBasedTableBuilder::WriteRawBlock(const Slice& block_contents,
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
r->status = r->io_status;
|
if (r->status.ok()) {
|
||||||
|
r->status = r->io_status;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
Status BlockBasedTableBuilder::status() const { return rep_->status; }
|
Status BlockBasedTableBuilder::status() const { return rep_->status; }
|
||||||
@ -1064,7 +1066,9 @@ void BlockBasedTableBuilder::WriteFooter(BlockHandle& metaindex_block_handle,
|
|||||||
if (r->io_status.ok()) {
|
if (r->io_status.ok()) {
|
||||||
r->offset += footer_encoding.size();
|
r->offset += footer_encoding.size();
|
||||||
}
|
}
|
||||||
r->status = r->io_status;
|
if (r->status.ok()) {
|
||||||
|
r->status = r->io_status;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
void BlockBasedTableBuilder::EnterUnbuffered() {
|
void BlockBasedTableBuilder::EnterUnbuffered() {
|
||||||
|
Loading…
Reference in New Issue
Block a user