Merge "libsnapshot: add compatibility check" into main
This commit is contained in:
commit
0ac91e1f02
1 changed files with 2 additions and 1 deletions
|
@ -685,7 +685,8 @@ ssize_t CowReader::ReadData(const CowOperation* op, void* buffer, size_t buffer_
|
|||
} else {
|
||||
offset = GetCowOpSourceInfoData(*op);
|
||||
}
|
||||
if (!decompressor || op->data_length == header_.block_size) {
|
||||
if (!decompressor ||
|
||||
((op->data_length == header_.block_size) && (header_.prefix.major_version == 3))) {
|
||||
CowDataStream stream(this, offset + ignore_bytes, op->data_length - ignore_bytes);
|
||||
return stream.ReadFully(buffer, buffer_size);
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue