read from buffers directly
This commit is contained in:
parent
b757e4bc23
commit
1003ca01bd
@ -510,7 +510,7 @@ def main():
|
||||
if event & select.POLLIN or event & select.POLLPRI:
|
||||
if rfd == proc.stdout.fileno():
|
||||
logger.debug("Reading from stdout...")
|
||||
if chunk := proc.stdout.read(PIPE_BUF):
|
||||
if chunk := proc.stdout.buffer.read(PIPE_BUF):
|
||||
logger.debug("Done, length %d", len(chunk))
|
||||
stdout_line_buffer.extend(chunk)
|
||||
while True:
|
||||
@ -524,7 +524,7 @@ def main():
|
||||
break
|
||||
if rfd == proc.stderr.fileno():
|
||||
logger.debug("Reading from stderr...")
|
||||
if chunk := proc.stderr.read(PIPE_BUF):
|
||||
if chunk := proc.stderr.buffer.read(PIPE_BUF):
|
||||
logger.debug("Done, length %d", len(chunk))
|
||||
stderr_line_buffer.extend(chunk)
|
||||
while True:
|
||||
|
||||
Loading…
Reference in New Issue
Block a user