comparison lisp/net/imap.el @ 100871:1d5b4a08955f

Gnus: Fix edge cases with no data being returned and Courier eccentricity. * lisp/gnus/nnimap.el (nnimap-retrieve-headers-progress): Handle edge case where `headers' is nil. This can occur if the IMAP server does not have permissions to read messages from a folder, but can write new messages to the folder. (nnimap-request-article-part): Do not insert `data' if it is nil. * lisp/net/imap.el (imap-parse-fetch): Courier can insert spurious blank characters which will confuse `read', so skip past them.
author Michael Olson <mwolson@gnu.org>
date Sat, 03 Jan 2009 23:05:42 +0000
parents 91e5880a36c1
children 8698a8bb7d0e
comparison
equal deleted inserted replaced
100870:373ba628faa9 100871:1d5b4a08955f
2491 2491
2492 (defun imap-parse-fetch (response) 2492 (defun imap-parse-fetch (response)
2493 (when (eq (char-after) ?\() 2493 (when (eq (char-after) ?\()
2494 (let (uid flags envelope internaldate rfc822 rfc822header rfc822text 2494 (let (uid flags envelope internaldate rfc822 rfc822header rfc822text
2495 rfc822size body bodydetail bodystructure flags-empty) 2495 rfc822size body bodydetail bodystructure flags-empty)
2496 (while (not (eq (char-after) ?\))) 2496 (while (let ((moved (skip-chars-forward " \t")))
2497 (prog1 (not (eq (char-after) ?\)))
2498 (unless (= moved 0) (backward-char))))
2497 (imap-forward) 2499 (imap-forward)
2498 (let ((token (read (current-buffer)))) 2500 (let ((token (read (current-buffer))))
2499 (imap-forward) 2501 (imap-forward)
2500 (cond ((eq token 'UID) 2502 (cond ((eq token 'UID)
2501 (setq uid (condition-case () 2503 (setq uid (condition-case ()