]> git-server-git.apps.pok.os.sepia.ceph.com Git - ceph-ci.git/commitdiff
client: clamp sizes to INT_MAX in sync i/o code paths
authorDhairya Parmar <dparmar@redhat.com>
Wed, 21 Aug 2024 12:24:16 +0000 (17:54 +0530)
committerJos Collin <jcollin@redhat.com>
Wed, 27 Aug 2025 06:45:04 +0000 (12:15 +0530)
Fixes: https://tracker.ceph.com/issues/67612
Signed-off-by: Dhairya Parmar <dparmar@redhat.com>
(cherry picked from commit d2699c4bcad979699d1d1b91a7fb53b010ec8dfb)

src/client/Client.cc

index 85e9e79e71005b38d6d4e1c30783fc2144de186a..7fb3fafcb2a574971ecf403f1cc4f41c58e61ad4 100644 (file)
@@ -16169,7 +16169,7 @@ int64_t Client::ll_writev(struct Fh *fh, const struct iovec *iov, int iovcnt, in
     ldout(cct, 3) << "(fh)" << fh << " is invalid" << dendl;
     return -EBADF;
   }
-  return _preadv_pwritev_locked(fh, iov, iovcnt, off, true, false);
+  return _preadv_pwritev_locked(fh, iov, iovcnt, off, true, true);
 }
 
 int64_t Client::ll_readv(struct Fh *fh, const struct iovec *iov, int iovcnt, int64_t off)
@@ -16184,7 +16184,7 @@ int64_t Client::ll_readv(struct Fh *fh, const struct iovec *iov, int iovcnt, int
     ldout(cct, 3) << "(fh)" << fh << " is invalid" << dendl;
     return -EBADF;
   }
-  return _preadv_pwritev_locked(fh, iov, iovcnt, off, false, false);
+  return _preadv_pwritev_locked(fh, iov, iovcnt, off, false, true);
 }
 
 int64_t Client::ll_preadv_pwritev(struct Fh *fh, const struct iovec *iov,