mirror of
https://github.com/ceph/ceph
synced 2025-02-23 11:07:35 +00:00
librbd: deep_copy: update end_size only if zero interval caused truncate
The problem shown up when stripping was used, and assembling a nonexistent destination object from source objects, and one of these objects existed and snap diff returned a zero interval. The non-zero end_size in that case triggered invalid object map update. Signed-off-by: Mykola Golub <mgolub@suse.com>
This commit is contained in:
parent
d3d730ce0f
commit
d1122573b8
@ -887,7 +887,7 @@ void ObjectCopyRequest<I>::compute_zero_ops() {
|
||||
ldout(m_cct, 20) << "COPY_OP_TYPE_TRUNC " << z.get_start() << dendl;
|
||||
}
|
||||
}
|
||||
end_size = z.get_start();
|
||||
end_size = std::min(end_size, z.get_start());
|
||||
} else {
|
||||
// zero interval inside the object
|
||||
m_write_ops[src_snap_seq]
|
||||
|
Loading…
Reference in New Issue
Block a user