From 3a937fe7bda97d17cd710f7b8c1fa9101be410fa Mon Sep 17 00:00:00 2001 From: dusoleil Date: Wed, 1 Sep 2021 00:18:09 -0400 Subject: Move "Read Rest of Output" Out of Destructor With the "read rest of output" code in the Comm destructor, it would continue to read output even in situations where some error happened and we expect sploit to die or when the user presses Ctrl+C to end sploit. By moving it to the end of the script running code in main, it behaves more intuitively. Signed-off-by: dusoleil --- sploit/comm.py | 4 ---- 1 file changed, 4 deletions(-) (limited to 'sploit/comm.py') diff --git a/sploit/comm.py b/sploit/comm.py index 040ddd6..59f8498 100644 --- a/sploit/comm.py +++ b/sploit/comm.py @@ -12,10 +12,6 @@ class Comm: def __init__(self, backend): self.back = backend - def __del__(self): - for line in self.back.stdin: - log(line) - def read(self, size): data = self.back.stdin.read(size) log(data) -- cgit v1.2.3