Method: gzip.GzipFile.read1
Calls: 7, Exceptions: 0, Paths: 2Back
Path 1: 5 calls (0.71)
8192 (5)
bytes (5)
1def read1(self, size=-1):
2 """Implements BufferedIOBase.read1()
3
4 Reads up to a buffer's worth of data if size is negative."""
5 self._check_not_closed()
6 if self.mode != READ:
7 import errno
8 raise OSError(errno.EBADF, "read1() on write-only GzipFile object")
9
10 if size < 0:
11 size = io.DEFAULT_BUFFER_SIZE
12 return self._buffer.read1(size)
Path 2: 2 calls (0.29)
-1 (2)
bytes (2)
1def read1(self, size=-1):
2 """Implements BufferedIOBase.read1()
3
4 Reads up to a buffer's worth of data if size is negative."""
5 self._check_not_closed()
6 if self.mode != READ:
7 import errno
8 raise OSError(errno.EBADF, "read1() on write-only GzipFile object")
9
10 if size < 0:
11 size = io.DEFAULT_BUFFER_SIZE
12 return self._buffer.read1(size)