--- a/tests/testlib/badserverext.py Fri Jan 21 01:07:50 2022 +0100
+++ b/tests/testlib/badserverext.py Sun Jan 23 21:25:01 2022 +0100
@@ -284,8 +284,8 @@
# No byte limit on this operation. Call original function.
if not remaining:
+ result = object.__getattribute__(self, '_orig').write(data)
self._writelog(b'write(%d) -> %s' % (len(data), data))
- result = object.__getattribute__(self, '_orig').write(data)
return result
if len(data) > remaining:
@@ -295,13 +295,13 @@
remaining -= len(newdata)
+ result = object.__getattribute__(self, '_orig').write(newdata)
+
self._writelog(
b'write(%d from %d) -> (%d) %s'
% (len(newdata), len(data), remaining, newdata)
)
- result = object.__getattribute__(self, '_orig').write(newdata)
-
object.__getattribute__(self, '_cond').remaining_send_bytes = remaining
if remaining <= 0: