]> git-server-git.apps.pok.os.sepia.ceph.com Git - ceph.git/commit
librbd: refactor merge() for SparseBufferlistExtent 55665/head
authorIlya Dryomov <idryomov@gmail.com>
Mon, 12 Feb 2024 12:07:22 +0000 (13:07 +0100)
committerIlya Dryomov <idryomov@gmail.com>
Tue, 20 Feb 2024 10:24:49 +0000 (11:24 +0100)
commit90174e72c614bbcc77c082b8c7ad12f5bb4ff456
tree444fc8fe45fcd177dae6264e33737fae85f866df
parent971aefce1dd38b71a3ff7998ae3492e871b1d217
librbd: refactor merge() for SparseBufferlistExtent

- pass left.length + right.length instead of bl.length()
  for consistency and to avoid circumventing the assert in
  SparseBufferlistExtent constructor
- claim_append() takes an lvalue reference, no need to move
- follow the pattern used in split()

Signed-off-by: Ilya Dryomov <idryomov@gmail.com>
(cherry picked from commit 69c18cfd291e63fbcd261d3cf20be8dfa0c7488d)
src/librbd/io/Types.h
src/test/librbd/io/test_mock_ObjectRequest.cc