]> git.apps.os.sepia.ceph.com Git - ceph.git/commit
client: in fcopyfile(), update len to read only leftover fragment
authorRishabh Dave <ridave@redhat.com>
Wed, 16 Jul 2025 16:04:18 +0000 (21:34 +0530)
committerChristopher Hoffman <choffman@redhat.com>
Wed, 5 Nov 2025 13:59:36 +0000 (13:59 +0000)
commitb1846d50eaa069e9403c2bf921d5328e85d08d13
tree50cf3bbf92ecc77573b064412635923689d97bf0
parent45fdea0304f706498d94db33226b3aa5879291b8
client: in fcopyfile(), update len to read only leftover fragment

fcopyfile() reads 1 MiB of data every time but when a fragment smaller
than 1 MiB is left, it still reads 1 MiB of data, causing to never meet
the condition of "off == size". This leads to an infinity loop which
continues to write until CephFS becomes full.

Resolves: rhbz#2379716
Fixes: https://tracker.ceph.com/issues/72238
Signed-off-by: Rishabh Dave <ridave@redhat.com>
src/client/Client.cc