Mercurial > cpython-lru_cache-weakref
diff Lib/socket.py @ 21962:d3b1f2c0ebcf legacy-trunk
The Grande 'sendall()' patch, copied from release21-maint. Fixes #516715.
Replaces calls to socket.send() (which isn't guaranteed to send all data)
with the new socket.sendall() method.
| author | Martin v. Löwis <martin@v.loewis.de> |
|---|---|
| date | Sat, 16 Feb 2002 23:06:19 +0000 |
| parents | 3957d155f8c5 |
| children | fce7278d46b0 |
line wrap: on
line diff
--- a/Lib/socket.py Sat Feb 16 18:47:07 2002 +0000 +++ b/Lib/socket.py Sat Feb 16 23:06:19 2002 +0000 @@ -185,7 +185,7 @@ def flush(self): if self._wbuf: - self._sock.send(self._wbuf) + self._sock.sendall(self._wbuf) self._wbuf = "" def fileno(self): @@ -201,7 +201,7 @@ self.flush() def writelines(self, list): - filter(self._sock.send, list) + filter(self._sock.sendall, list) self.flush() def read(self, n=-1):
