diff options
Diffstat (limited to 'Lib')
-rwxr-xr-x | Lib/mailbox.py | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/Lib/mailbox.py b/Lib/mailbox.py index 6d5f6e4..b6c16fe 100755 --- a/Lib/mailbox.py +++ b/Lib/mailbox.py @@ -97,13 +97,16 @@ class UnixMailbox(_Mailbox): def _search_start(self): while 1: + pos = self.fp.tell() line = self.fp.readline() if not line: raise EOFError if line[:5] == 'From ' and self._isrealfromline(line): + self.fp.seek(pos) return def _search_end(self): + self.fp.readline() # Throw away header line while 1: pos = self.fp.tell() line = self.fp.readline() |