diff options
author | dusoleil <howcansocksbereal@gmail.com> | 2021-09-01 00:56:40 -0400 |
---|---|---|
committer | dusoleil <howcansocksbereal@gmail.com> | 2021-09-01 00:56:40 -0400 |
commit | a5d0003aa8f3f14076945a9a01ea23915be874dc (patch) | |
tree | cba7ccedd874470c42162f13ec9ead6069f72459 | |
parent | 0aad1e71f0bc1343d9d41c19709458e9131c19fc (diff) | |
download | lib-des-gnux-a5d0003aa8f3f14076945a9a01ea23915be874dc.tar.gz lib-des-gnux-a5d0003aa8f3f14076945a9a01ea23915be874dc.zip |
Throw a BrokenPipeError on Broken Read
Signed-off-by: dusoleil <howcansocksbereal@gmail.com>
-rw-r--r-- | tools/sploit/sploit/comm.py | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/tools/sploit/sploit/comm.py b/tools/sploit/sploit/comm.py index 1f55fb6..fc220ef 100644 --- a/tools/sploit/sploit/comm.py +++ b/tools/sploit/sploit/comm.py @@ -14,11 +14,15 @@ class Comm: def read(self, size): data = self.back.stdin.read(size) + if(data == b''): + raise BrokenPipeError('Tried to read on broken pipe') log(data) return data def readline(self): data = self.back.stdin.readline() + if(data == b''): + raise BrokenPipeError('Tried to read on broken pipe') log(data) return data |