summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorWang Chao <sean10reborn@gmail.com>2024-08-10 13:40:52 +0200
committerWang Chao <sean10reborn@gmail.com>2024-11-05 17:17:19 +0100
commit049d7d35abe0aa2560e3bb9d4fafb43eefb4a0ed (patch)
treed74d7e8b702c4cbfc8458ff338a10528ec7075cf
parentMerge pull request #56832 from Matan-B/wip-matanb-crimson-recovery-version (diff)
downloadceph-049d7d35abe0aa2560e3bb9d4fafb43eefb4a0ed.tar.xz
ceph-049d7d35abe0aa2560e3bb9d4fafb43eefb4a0ed.zip
pybind/rados: fix the incorrect order of offset,length in WriteOp.zero
The offset and length parameters in the rados pybind `WriteOp.zero()` method are being passed to the rados_write_op_zero() function in the incorrect order. Incorrect order cause OP_ZERO not work correctly when use pybind's rados. Signed-off-by: Wang Chao <sean10reborn@gmail.com>
-rw-r--r--src/pybind/rados/rados.pyx2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/pybind/rados/rados.pyx b/src/pybind/rados/rados.pyx
index b54ebb483c6..bcfa6777f3d 100644
--- a/src/pybind/rados/rados.pyx
+++ b/src/pybind/rados/rados.pyx
@@ -1870,7 +1870,7 @@ cdef class WriteOp(object):
uint64_t _offset = offset
with nogil:
- rados_write_op_zero(self.write_op, _length, _offset)
+ rados_write_op_zero(self.write_op, _offset, _length)
def truncate(self, offset: int):
"""