summaryrefslogtreecommitdiff
path: root/Lib/imaplib.py
diff options
context:
space:
mode:
Diffstat (limited to 'Lib/imaplib.py')
-rw-r--r--Lib/imaplib.py9
1 files changed, 1 insertions, 8 deletions
diff --git a/Lib/imaplib.py b/Lib/imaplib.py
index 04d4d87bb9..03513a36b2 100644
--- a/Lib/imaplib.py
+++ b/Lib/imaplib.py
@@ -222,14 +222,7 @@ class IMAP4:
def send(self, data):
"""Send data to remote."""
- bytes = len(data)
- while bytes > 0:
- sent = self.sock.send(data)
- if sent == bytes:
- break # avoid copy
- data = data[sent:]
- bytes = bytes - sent
-
+ self.sock.sendall(data)
def shutdown(self):
"""Close I/O established in "open"."""