SF bug #469910 by Alfonso Baciero: Bugfix for imaplib for macintosh
Pass binary mode to makefile().
This commit is contained in:
parent
327798ca4a
commit
c0f1bfec05
|
@ -207,7 +207,7 @@ class IMAP4:
|
|||
"""
|
||||
self.sock = socket.socket(socket.AF_INET, socket.SOCK_STREAM)
|
||||
self.sock.connect((self.host, self.port))
|
||||
self.file = self.sock.makefile('r')
|
||||
self.file = self.sock.makefile('rb')
|
||||
|
||||
|
||||
def read(self, size):
|
||||
|
|
Loading…
Reference in New Issue