diff options
Diffstat (limited to 'Lib/telnetlib.py')
-rw-r--r-- | Lib/telnetlib.py | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/Lib/telnetlib.py b/Lib/telnetlib.py index 15721c6e6f..cdbbd9f5cc 100644 --- a/Lib/telnetlib.py +++ b/Lib/telnetlib.py @@ -269,7 +269,7 @@ class Telnet: if IAC in buffer: buffer = buffer.replace(IAC, IAC+IAC) self.msg("send %s", `buffer`) - self.sock.send(buffer) + self.sock.sendall(buffer) def read_until(self, match, timeout=None): """Read until a given string is encountered or until timeout. @@ -411,7 +411,7 @@ class Telnet: if self.option_callback: self.option_callback(self.sock, c, opt) else: - self.sock.send(IAC + WONT + opt) + self.sock.sendall(IAC + WONT + opt) elif c in (WILL, WONT): opt = self.rawq_getchar() self.msg('IAC %s %d', @@ -419,7 +419,7 @@ class Telnet: if self.option_callback: self.option_callback(self.sock, c, opt) else: - self.sock.send(IAC + DONT + opt) + self.sock.sendall(IAC + DONT + opt) else: self.msg('IAC %d not recognized' % ord(opt)) except EOFError: # raised by self.rawq_getchar() |