Skip to content

Commit 049d7d3

Browse files
committed
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 <[email protected]>
1 parent a91bcae commit 049d7d3

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/pybind/rados/rados.pyx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1870,7 +1870,7 @@ cdef class WriteOp(object):
18701870
uint64_t _offset = offset
18711871

18721872
with nogil:
1873-
rados_write_op_zero(self.write_op, _length, _offset)
1873+
rados_write_op_zero(self.write_op, _offset, _length)
18741874

18751875
def truncate(self, offset: int):
18761876
"""

0 commit comments

Comments
 (0)