We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 61691d8 commit 3e04cd2Copy full SHA for 3e04cd2
Lib/test/libregrtest/win_utils.py
@@ -32,6 +32,7 @@ class WindowsLoadTracker():
32
def __init__(self):
33
self.load = 0.0
34
self.counter_name = ''
35
+ self._buffer = b''
36
self.popen = None
37
self.start()
38
@@ -100,7 +101,9 @@ def read_output(self):
100
101
if res != 0:
102
return
103
- output = overlapped.getbuffer()
104
+ # self._buffer stores an incomplete line
105
+ output = self._buffer + overlapped.getbuffer()
106
+ output, _, self._buffer = output.rpartition(b'\n')
107
return output.decode('oem', 'replace')
108
109
def getloadavg(self):
0 commit comments