diff Lib/httplib.py @ 21963:2faa23facef7 2.2

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:08:25 +0000
parents 3adc3a14cde4
children d6d12e21d44f
line wrap: on
line diff
--- a/Lib/httplib.py	Fri Feb 15 21:00:17 2002 +0000
+++ b/Lib/httplib.py	Sat Feb 16 23:08:25 2002 +0000
@@ -403,7 +403,7 @@
         if self.debuglevel > 0:
             print "send:", repr(str)
         try:
-            self.sock.send(str)
+            self.sock.sendall(str)
         except socket.error, v:
             if v[0] == 32:      # Broken pipe
                 self.close()