Skip to content

Commit 5bef1e4

Browse files
Fixed bug resulting in an infinite loop when a fixed buffer is exhausted
at the end of one of the internal fields.
1 parent 5f5f817 commit 5bef1e4

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

src/oracledb/impl/base/buffer.pyx

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -411,6 +411,8 @@ cdef class Buffer:
411411
cdef ssize_t num_bytes_this_time
412412
while num_bytes > 0:
413413
num_bytes_this_time = min(num_bytes, self.bytes_left())
414+
if num_bytes_this_time == 0:
415+
num_bytes_this_time = num_bytes
414416
self._get_raw(num_bytes_this_time)
415417
num_bytes -= num_bytes_this_time
416418

0 commit comments

Comments
 (0)