[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[VM] (wrong-type-argument char-or-string-p nil) while fetching mail in I
From: |
Joe Malcolm |
Subject: |
[VM] (wrong-type-argument char-or-string-p nil) while fetching mail in IMAP folder |
Date: |
Wed, 4 Nov 2015 15:46:48 +0000 |
Running 8.2.0b, I am getting a new error when fetching mail in an IMAP
folder. Stack track (from uncompiled elisp) below. Anyone else seeing
this?
When this first started happening yesterday, I deleted the local file
and let VM refetch all messages. That helped for about 12 hours and
then the error popped up again.
FWIW: there are currently 1657 messages in the folder. The server on
the other end is dovecot. I haven't changed the mail configuration
recently, or anything to do with emacs, recently, but specificially
since this started to heppen.
Joe
Debugger entered--Lisp error: (wrong-type-argument char-or-string-p nil)
insert(nil)
(let ((***start vm-imap-read-point) end fetch-response list p) (goto-char
***start) (vm-set-imap-status-got statblob 0) (let* ((func (function (lambda
(beg end len) (if vm-imap-read-point (progn ... ...)))))
(after-change-functions (cons func after-change-functions)) (need-ok t)
response) (condition-case err (setq response (vm-imap-read-response-and-verify
process "message FETCH")) (error (vm-imap-normal-error (error-message-string
err))) (quit (vm-imap-normal-error "quit signal received during retrieval")))
(cond ((vm-imap-response-matches response (quote *) (quote atom) (quote FETCH)
(quote list)) (setq fetch-response response)) (t (vm-imap-normal-error "cannot
retrieve message from the server")))) (setq vm-imap-read-point (point-marker))
(setq list (cdr (nth 3 fetch-response))) (cond (bodypeek (cond
((vm-imap-response-matches list (quote BODY) (quote (vector)) (quote string))
(setq p (nth 2 list) ***start (nth 1 p))) ((vm-imap-response-matches list
(quote UID) (quote atom) (quote BODY) (quote (vector)) (quote string)) (setq p
(nth 4 list) ***start (nth 1 p))) (t (vm-imap-protocol-error "expected (BODY[]
string) in FETCH response")))) (t (if (not (vm-imap-response-matches list
(quote RFC822) (quote string))) (vm-imap-protocol-error "expected (RFC822
string) in FETCH response")) (setq p (nth 1 list) ***start (nth 1 p))))
(goto-char (nth 2 p)) (setq end (point-marker)) (vm-set-imap-status-need
statblob nil) (vm-imap-cleanup-region ***start end)
(vm-munge-message-separators vm-folder-type ***start end) (goto-char ***start)
(vm-set-imap-status-got statblob nil) (if (and (eq vm-folder-type (quote
babyl)) (cond ((stringp target) (let ((attrs ...)) (or (null attrs) (equal 0
...)))) ((bufferp target) (save-current-buffer (set-buffer target) (zerop
(buffer-size)))))) (let ((opoint (point))) (vm-convert-folder-header nil
vm-folder-type) (setq ***start opoint) (goto-char ***start)
(vm-skip-past-folder-header))) (insert (vm-leading-message-separator))
(save-restriction (narrow-to-region (point) end)
(vm-convert-folder-type-headers (quote baremessage) vm-folder-type)) (goto-char
end) (if (and (not (eq 10 (char-after (1- (point))))) (memq vm-folder-type
(quote (From_-with-Content-Length BellFrom_ From_)))) (insert-before-markers
"\n")) (insert-before-markers (vm-trailing-message-separator)) (if (stringp
target) (let ((buffer-file-type t) (selective-display nil)) (write-region
***start end target t 0)) (let ((b (current-buffer))) (save-current-buffer
(set-buffer target) (vm-buffer-type:enter (quote unknown)) (let
((buffer-read-only nil)) (insert-buffer-substring b ***start end))
(vm-buffer-type:exit)))) (delete-region ***start end) t)
vm-imap-retrieve-to-target(#<process IMAP over SSL<1>> #<buffer INBOX<2>>
[[nil 22074 9751 298460 2 vm-imap-report-retrieval-status (#0) nil 680000] t
"address@hidden:INBOX" 0 31 nil nil "address@hidden:INBOX" 0 31 228903 31166]
(IMAP4REV1 LITERAL+ SASL-IR LOGIN-REFERRALS ID ENABLE IDLE))
(while (> k 0) (vm-imap-retrieve-to-target process folder-buffer statblob
use-body-peek) (save-current-buffer (set-buffer folder-buffer) (if (= (point)
pos) (debug "IMAP internal error #2012: the point hasn't moved"))) (setq k (1-
k)))
(while r-list (setq pair (car r-list) range (car pair) headers-only (cadr
pair)) (vm-set-imap-status-currmsg statblob n) (setq message-size
(vm-imap-get-message-size process (car range))) (vm-set-imap-status-need
statblob message-size) (vm-imap-session-type:assert (quote valid))
(vm-imap-fetch-messages process (car range) (cdr range) use-body-peek
headers-only) (setq k (1+ (- (cdr range) (car range)))) (setq pos
(save-current-buffer (set-buffer folder-buffer) (point))) (while (> k 0)
(vm-imap-retrieve-to-target process folder-buffer statblob use-body-peek)
(save-current-buffer (set-buffer folder-buffer) (if (= (point) pos) (debug
"IMAP internal error #2012: the point hasn't moved"))) (setq k (1- k)))
(vm-imap-read-ok-response process) (setq r-list (cdr r-list) n (+ n (1+ (- (cdr
range) (car range))))))
(save-excursion (set-buffer (process-buffer process)) (vm-buffer-type:enter
(quote process)) (setq statblob (vm-imap-start-status-timer))
(vm-set-imap-status-mailbox statblob folder) (vm-set-imap-status-maxmsg
statblob (length retrieve-list)) (while r-list (setq pair (car r-list) range
(car pair) headers-only (cadr pair)) (vm-set-imap-status-currmsg statblob n)
(setq message-size (vm-imap-get-message-size process (car range)))
(vm-set-imap-status-need statblob message-size) (vm-imap-session-type:assert
(quote valid)) (vm-imap-fetch-messages process (car range) (cdr range)
use-body-peek headers-only) (setq k (1+ (- (cdr range) (car range)))) (setq pos
(save-current-buffer (set-buffer folder-buffer) (point))) (while (> k 0)
(vm-imap-retrieve-to-target process folder-buffer statblob use-body-peek)
(save-current-buffer (set-buffer folder-buffer) (if (= (point) pos) (debug
"IMAP internal error #2012: the point hasn't moved"))) (setq k (1- k)))
(vm-imap-read-ok-response process) (setq r-list (cdr r-list) n (+ n (1+ (- (cdr
range) (car range)))))))
(condition-case error-data (save-excursion (set-buffer (process-buffer
process)) (vm-buffer-type:enter (quote process)) (setq statblob
(vm-imap-start-status-timer)) (vm-set-imap-status-mailbox statblob folder)
(vm-set-imap-status-maxmsg statblob (length retrieve-list)) (while r-list (setq
pair (car r-list) range (car pair) headers-only (cadr pair))
(vm-set-imap-status-currmsg statblob n) (setq message-size
(vm-imap-get-message-size process (car range))) (vm-set-imap-status-need
statblob message-size) (vm-imap-session-type:assert (quote valid))
(vm-imap-fetch-messages process (car range) (cdr range) use-body-peek
headers-only) (setq k (1+ (- (cdr range) (car range)))) (setq pos
(save-current-buffer (set-buffer folder-buffer) (point))) (while (> k 0)
(vm-imap-retrieve-to-target process folder-buffer statblob use-body-peek)
(save-current-buffer (set-buffer folder-buffer) (if (= (point) pos) (debug
"IMAP internal error #2012: the point hasn't moved"))) (setq k (1- k)))
(vm-imap-read-ok-response process) (setq r-list (cdr r-list) n (+ n (1+ (- (cdr
range) (car range))))))) (vm-imap-normal-error (vm-warn 0 2 "IMAP error: %s"
(cadr error-data))) (vm-imap-protocol-error (vm-warn 0 2 "Retrieval from %s
signaled: %s" folder error-data)) (quit (delete-region old-eob (point-max))
(error (format "Quit received during retrieval from %s" folder))))
(unwind-protect (condition-case error-data (save-excursion (set-buffer
(process-buffer process)) (vm-buffer-type:enter (quote process)) (setq statblob
(vm-imap-start-status-timer)) (vm-set-imap-status-mailbox statblob folder)
(vm-set-imap-status-maxmsg statblob (length retrieve-list)) (while r-list (setq
pair (car r-list) range (car pair) headers-only (cadr pair))
(vm-set-imap-status-currmsg statblob n) (setq message-size
(vm-imap-get-message-size process (car range))) (vm-set-imap-status-need
statblob message-size) (vm-imap-session-type:assert (quote valid))
(vm-imap-fetch-messages process (car range) (cdr range) use-body-peek
headers-only) (setq k (1+ (- (cdr range) (car range)))) (setq pos
(save-current-buffer (set-buffer folder-buffer) (point))) (while (> k 0)
(vm-imap-retrieve-to-target process folder-buffer statblob use-body-peek)
(save-current-buffer (set-buffer folder-buffer) (if (= ... pos) (debug "IMAP
internal error #2012: the point hasn't moved"))) (setq k (1- k)))
(vm-imap-read-ok-response process) (setq r-list (cdr r-list) n (+ n (1+ (- ...
...)))))) (vm-imap-normal-error (vm-warn 0 2 "IMAP error: %s" (cadr
error-data))) (vm-imap-protocol-error (vm-warn 0 2 "Retrieval from %s signaled:
%s" folder error-data)) (quit (delete-region old-eob (point-max)) (error
(format "Quit received during retrieval from %s" folder)))) (if statblob (progn
(vm-imap-stop-status-timer statblob))) (vm-buffer-type:exit))
(progn (widen) (setq old-eob (point-max)) (goto-char (point-max)) (if (null
vm-imap-max-message-size) (progn (setq vm-imap-max-message-size
most-positive-fixnum))) (setq retrieve-list (mapcar (function (lambda (pair)
(if (> (read ...) vm-imap-max-message-size) (list (car pair) (cdr pair)
headers-only) (list (car pair) (cdr pair) nil)))) retrieve-list)) (setq r-list
(vm-imap-bunch-retrieve-list (mapcar (function cdr) retrieve-list)))
(unwind-protect (condition-case error-data (save-excursion (set-buffer
(process-buffer process)) (vm-buffer-type:enter (quote process)) (setq statblob
(vm-imap-start-status-timer)) (vm-set-imap-status-mailbox statblob folder)
(vm-set-imap-status-maxmsg statblob (length retrieve-list)) (while r-list (setq
pair (car r-list) range (car pair) headers-only (cadr pair))
(vm-set-imap-status-currmsg statblob n) (setq message-size
(vm-imap-get-message-size process (car range))) (vm-set-imap-status-need
statblob message-size) (vm-imap-session-type:assert (quote valid))
(vm-imap-fetch-messages process (car range) (cdr range) use-body-peek
headers-only) (setq k (1+ (- ... ...))) (setq pos (save-current-buffer
(set-buffer folder-buffer) (point))) (while (> k 0) (vm-imap-retrieve-to-target
process folder-buffer statblob use-body-peek) (save-current-buffer (set-buffer
folder-buffer) (if ... ...)) (setq k (1- k))) (vm-imap-read-ok-response
process) (setq r-list (cdr r-list) n (+ n (1+ ...))))) (vm-imap-normal-error
(vm-warn 0 2 "IMAP error: %s" (cadr error-data))) (vm-imap-protocol-error
(vm-warn 0 2 "Retrieval from %s signaled: %s" folder error-data)) (quit
(delete-region old-eob (point-max)) (error (format "Quit received during
retrieval from %s" folder)))) (if statblob (progn (vm-imap-stop-status-timer
statblob))) (vm-buffer-type:exit)) (setq vm-spooled-mail-waiting nil)
(vm-set-folder-imap-retrieved-count (vm-folder-imap-mailbox-count)) (intern
(buffer-name) vm-buffers-needing-display-update) (vm-inform 6 "%s: Updating
summary... " (buffer-name folder-buffer)) (vm-update-summary-and-mode-line)
(setq mp (vm-assimilate-new-messages :read-attributes nil)) (setq new-messages
mp) (if new-messages (setq vm-modification-counter (1+
vm-modification-counter))) (setq r-list retrieve-list) (while mp (setq r-entry
(car r-list) uid (car r-entry) headers-only (nth 2 r-entry)) (if headers-only
(progn (vm-set-body-to-be-retrieved-of (car mp) t)
(vm-set-body-to-be-discarded-of (car mp) nil))) (vm-set-imap-uid-of (car mp)
uid) (vm-set-imap-uid-validity-of (car mp) uid-validity) (vm-set-byte-count-of
(car mp) (vm-folder-imap-uid-message-size uid)) (vm-imap-update-message-flags
(car mp) (vm-folder-imap-uid-message-flags uid) t) (vm-mark-for-summary-update
(car mp)) (vm-set-stuff-flag-of (car mp) t) (setq mp (cdr mp) r-list (cdr
r-list))) (if vm-arrived-message-hook (progn (mapc (function (lambda (m)
(vm-run-hook-on-message (quote vm-arrived-message-hook) m))) new-messages)))
(run-hooks (quote vm-arrived-messages-hook)) new-messages)
(unwind-protect (progn (widen) (setq old-eob (point-max)) (goto-char
(point-max)) (if (null vm-imap-max-message-size) (progn (setq
vm-imap-max-message-size most-positive-fixnum))) (setq retrieve-list (mapcar
(function (lambda (pair) (if (> ... vm-imap-max-message-size) (list ... ...
headers-only) (list ... ... nil)))) retrieve-list)) (setq r-list
(vm-imap-bunch-retrieve-list (mapcar (function cdr) retrieve-list)))
(unwind-protect (condition-case error-data (save-excursion (set-buffer
(process-buffer process)) (vm-buffer-type:enter (quote process)) (setq statblob
(vm-imap-start-status-timer)) (vm-set-imap-status-mailbox statblob folder)
(vm-set-imap-status-maxmsg statblob (length retrieve-list)) (while r-list (setq
pair (car r-list) range (car pair) headers-only (cadr pair))
(vm-set-imap-status-currmsg statblob n) (setq message-size
(vm-imap-get-message-size process ...)) (vm-set-imap-status-need statblob
message-size) (vm-imap-session-type:assert (quote valid))
(vm-imap-fetch-messages process (car range) (cdr range) use-body-peek
headers-only) (setq k (1+ ...)) (setq pos (save-current-buffer ... ...)) (while
(> k 0) (vm-imap-retrieve-to-target process folder-buffer statblob
use-body-peek) (save-current-buffer ... ...) (setq k ...))
(vm-imap-read-ok-response process) (setq r-list (cdr r-list) n (+ n ...))))
(vm-imap-normal-error (vm-warn 0 2 "IMAP error: %s" (cadr error-data)))
(vm-imap-protocol-error (vm-warn 0 2 "Retrieval from %s signaled: %s" folder
error-data)) (quit (delete-region old-eob (point-max)) (error (format "Quit
received during retrieval from %s" folder)))) (if statblob (progn
(vm-imap-stop-status-timer statblob))) (vm-buffer-type:exit)) (setq
vm-spooled-mail-waiting nil) (vm-set-folder-imap-retrieved-count
(vm-folder-imap-mailbox-count)) (intern (buffer-name)
vm-buffers-needing-display-update) (vm-inform 6 "%s: Updating summary... "
(buffer-name folder-buffer)) (vm-update-summary-and-mode-line) (setq mp
(vm-assimilate-new-messages :read-attributes nil)) (setq new-messages mp) (if
new-messages (setq vm-modification-counter (1+ vm-modification-counter))) (setq
r-list retrieve-list) (while mp (setq r-entry (car r-list) uid (car r-entry)
headers-only (nth 2 r-entry)) (if headers-only (progn
(vm-set-body-to-be-retrieved-of (car mp) t) (vm-set-body-to-be-discarded-of
(car mp) nil))) (vm-set-imap-uid-of (car mp) uid) (vm-set-imap-uid-validity-of
(car mp) uid-validity) (vm-set-byte-count-of (car mp)
(vm-folder-imap-uid-message-size uid)) (vm-imap-update-message-flags (car mp)
(vm-folder-imap-uid-message-flags uid) t) (vm-mark-for-summary-update (car mp))
(vm-set-stuff-flag-of (car mp) t) (setq mp (cdr mp) r-list (cdr r-list))) (if
vm-arrived-message-hook (progn (mapc (function (lambda (m)
(vm-run-hook-on-message ... m))) new-messages))) (run-hooks (quote
vm-arrived-messages-hook)) new-messages) (widen) (and vm-sr-clip (progn
(narrow-to-region vm-sr-min vm-sr-max) (set-marker vm-sr-min nil) (set-marker
vm-sr-max nil))))
(let ((vm-sr-clip (> (buffer-size) (- (point-max) (point-min)))) vm-sr-min
vm-sr-max) (and vm-sr-clip (setq vm-sr-min (set-marker (make-marker)
(point-min))) (setq vm-sr-max (set-marker (make-marker) (point-max))))
(unwind-protect (progn (widen) (setq old-eob (point-max)) (goto-char
(point-max)) (if (null vm-imap-max-message-size) (progn (setq
vm-imap-max-message-size most-positive-fixnum))) (setq retrieve-list (mapcar
(function (lambda (pair) (if ... ... ...))) retrieve-list)) (setq r-list
(vm-imap-bunch-retrieve-list (mapcar (function cdr) retrieve-list)))
(unwind-protect (condition-case error-data (save-excursion (set-buffer
(process-buffer process)) (vm-buffer-type:enter (quote process)) (setq statblob
(vm-imap-start-status-timer)) (vm-set-imap-status-mailbox statblob folder)
(vm-set-imap-status-maxmsg statblob (length retrieve-list)) (while r-list (setq
pair ... range ... headers-only ...) (vm-set-imap-status-currmsg statblob n)
(setq message-size ...) (vm-set-imap-status-need statblob message-size)
(vm-imap-session-type:assert ...) (vm-imap-fetch-messages process ... ...
use-body-peek headers-only) (setq k ...) (setq pos ...) (while ... ... ... ...)
(vm-imap-read-ok-response process) (setq r-list ... n ...)))
(vm-imap-normal-error (vm-warn 0 2 "IMAP error: %s" (cadr error-data)))
(vm-imap-protocol-error (vm-warn 0 2 "Retrieval from %s signaled: %s" folder
error-data)) (quit (delete-region old-eob (point-max)) (error (format "Quit
received during retrieval from %s" folder)))) (if statblob (progn
(vm-imap-stop-status-timer statblob))) (vm-buffer-type:exit)) (setq
vm-spooled-mail-waiting nil) (vm-set-folder-imap-retrieved-count
(vm-folder-imap-mailbox-count)) (intern (buffer-name)
vm-buffers-needing-display-update) (vm-inform 6 "%s: Updating summary... "
(buffer-name folder-buffer)) (vm-update-summary-and-mode-line) (setq mp
(vm-assimilate-new-messages :read-attributes nil)) (setq new-messages mp) (if
new-messages (setq vm-modification-counter (1+ vm-modification-counter))) (setq
r-list retrieve-list) (while mp (setq r-entry (car r-list) uid (car r-entry)
headers-only (nth 2 r-entry)) (if headers-only (progn
(vm-set-body-to-be-retrieved-of (car mp) t) (vm-set-body-to-be-discarded-of
(car mp) nil))) (vm-set-imap-uid-of (car mp) uid) (vm-set-imap-uid-validity-of
(car mp) uid-validity) (vm-set-byte-count-of (car mp)
(vm-folder-imap-uid-message-size uid)) (vm-imap-update-message-flags (car mp)
(vm-folder-imap-uid-message-flags uid) t) (vm-mark-for-summary-update (car mp))
(vm-set-stuff-flag-of (car mp) t) (setq mp (cdr mp) r-list (cdr r-list))) (if
vm-arrived-message-hook (progn (mapc (function (lambda ... ...))
new-messages))) (run-hooks (quote vm-arrived-messages-hook)) new-messages)
(widen) (and vm-sr-clip (progn (narrow-to-region vm-sr-min vm-sr-max)
(set-marker vm-sr-min nil) (set-marker vm-sr-max nil)))))
(save-excursion (vm-inform 6 "%s: Retrieving new messages... " (buffer-name
folder-buffer)) (let ((vm-sr-clip (> (buffer-size) (- (point-max)
(point-min)))) vm-sr-min vm-sr-max) (and vm-sr-clip (setq vm-sr-min (set-marker
(make-marker) (point-min))) (setq vm-sr-max (set-marker (make-marker)
(point-max)))) (unwind-protect (progn (widen) (setq old-eob (point-max))
(goto-char (point-max)) (if (null vm-imap-max-message-size) (progn (setq
vm-imap-max-message-size most-positive-fixnum))) (setq retrieve-list (mapcar
(function (lambda ... ...)) retrieve-list)) (setq r-list
(vm-imap-bunch-retrieve-list (mapcar (function cdr) retrieve-list)))
(unwind-protect (condition-case error-data (save-excursion (set-buffer ...)
(vm-buffer-type:enter ...) (setq statblob ...) (vm-set-imap-status-mailbox
statblob folder) (vm-set-imap-status-maxmsg statblob ...) (while r-list ... ...
... ... ... ... ... ... ... ... ...)) (vm-imap-normal-error (vm-warn 0 2 "IMAP
error: %s" ...)) (vm-imap-protocol-error (vm-warn 0 2 "Retrieval from %s
signaled: %s" folder error-data)) (quit (delete-region old-eob ...) (error
...))) (if statblob (progn (vm-imap-stop-status-timer statblob)))
(vm-buffer-type:exit)) (setq vm-spooled-mail-waiting nil)
(vm-set-folder-imap-retrieved-count (vm-folder-imap-mailbox-count)) (intern
(buffer-name) vm-buffers-needing-display-update) (vm-inform 6 "%s: Updating
summary... " (buffer-name folder-buffer)) (vm-update-summary-and-mode-line)
(setq mp (vm-assimilate-new-messages :read-attributes nil)) (setq new-messages
mp) (if new-messages (setq vm-modification-counter (1+
vm-modification-counter))) (setq r-list retrieve-list) (while mp (setq r-entry
(car r-list) uid (car r-entry) headers-only (nth 2 r-entry)) (if headers-only
(progn (vm-set-body-to-be-retrieved-of ... t) (vm-set-body-to-be-discarded-of
... nil))) (vm-set-imap-uid-of (car mp) uid) (vm-set-imap-uid-validity-of (car
mp) uid-validity) (vm-set-byte-count-of (car mp)
(vm-folder-imap-uid-message-size uid)) (vm-imap-update-message-flags (car mp)
(vm-folder-imap-uid-message-flags uid) t) (vm-mark-for-summary-update (car mp))
(vm-set-stuff-flag-of (car mp) t) (setq mp (cdr mp) r-list (cdr r-list))) (if
vm-arrived-message-hook (progn (mapc (function ...) new-messages))) (run-hooks
(quote vm-arrived-messages-hook)) new-messages) (widen) (and vm-sr-clip (progn
(narrow-to-region vm-sr-min vm-sr-max) (set-marker vm-sr-min nil) (set-marker
vm-sr-max nil))))))
(let* ((folder-buffer (current-buffer)) (process (vm-folder-imap-process))
(imapdrop (vm-folder-imap-maildrop-spec)) (folder (or (vm-imap-folder-for-spec
imapdrop) (vm-safe-imapdrop-string imapdrop))) (use-body-peek
(vm-folder-imap-body-peek)) (uid-validity (vm-folder-imap-uid-validity)) uid
r-list r-entry range new-messages message-size statblob old-eob pos k mp pair
(headers-only (or (eq vm-enable-external-messages t) (memq (quote imap)
vm-enable-external-messages))) (n 0)) (save-excursion (vm-inform 6 "%s:
Retrieving new messages... " (buffer-name folder-buffer)) (let ((vm-sr-clip (>
(buffer-size) (- (point-max) (point-min)))) vm-sr-min vm-sr-max) (and
vm-sr-clip (setq vm-sr-min (set-marker (make-marker) (point-min))) (setq
vm-sr-max (set-marker (make-marker) (point-max)))) (unwind-protect (progn
(widen) (setq old-eob (point-max)) (goto-char (point-max)) (if (null
vm-imap-max-message-size) (progn (setq vm-imap-max-message-size
most-positive-fixnum))) (setq retrieve-list (mapcar (function ...)
retrieve-list)) (setq r-list (vm-imap-bunch-retrieve-list (mapcar ...
retrieve-list))) (unwind-protect (condition-case error-data (save-excursion ...
... ... ... ... ...) (vm-imap-normal-error ...) (vm-imap-protocol-error ...)
(quit ... ...)) (if statblob (progn ...)) (vm-buffer-type:exit)) (setq
vm-spooled-mail-waiting nil) (vm-set-folder-imap-retrieved-count
(vm-folder-imap-mailbox-count)) (intern (buffer-name)
vm-buffers-needing-display-update) (vm-inform 6 "%s: Updating summary... "
(buffer-name folder-buffer)) (vm-update-summary-and-mode-line) (setq mp
(vm-assimilate-new-messages :read-attributes nil)) (setq new-messages mp) (if
new-messages (setq vm-modification-counter (1+ vm-modification-counter))) (setq
r-list retrieve-list) (while mp (setq r-entry (car r-list) uid (car r-entry)
headers-only (nth 2 r-entry)) (if headers-only (progn ... ...))
(vm-set-imap-uid-of (car mp) uid) (vm-set-imap-uid-validity-of (car mp)
uid-validity) (vm-set-byte-count-of (car mp) (vm-folder-imap-uid-message-size
uid)) (vm-imap-update-message-flags (car mp) (vm-folder-imap-uid-message-flags
uid) t) (vm-mark-for-summary-update (car mp)) (vm-set-stuff-flag-of (car mp) t)
(setq mp (cdr mp) r-list (cdr r-list))) (if vm-arrived-message-hook (progn
(mapc ... new-messages))) (run-hooks (quote vm-arrived-messages-hook))
new-messages) (widen) (and vm-sr-clip (progn (narrow-to-region vm-sr-min
vm-sr-max) (set-marker vm-sr-min nil) (set-marker vm-sr-max nil)))))))
vm-imap-retrieve-messages((("4988" . 1658) ("4989" . 1659) ("4990" . 1660)
("4991" . 1661) ("4992" . 1662) ("4993" . 1663) ("4994" . 1664) ("4995" . 1665)
("4996" . 1666) ("4997" . 1667) ("4998" . 1668) ("4999" . 1669) ("5000" . 1670)
("5001" . 1671) ("5002" . 1672) ("5003" . 1673) ("5004" . 1674) ("5005" . 1675)
("5006" . 1676) ("5007" . 1677) ("5008" . 1678) ("5009" . 1679) ("5010" . 1680)
("5011" . 1681) ("5012" . 1682) ("5013" . 1683) ("5014" . 1684) ("5015" . 1685)
("5016" . 1686) ("5017" . 1687) ("5018" . 1688)))
(setq new-messages (vm-imap-retrieve-messages retrieve-list))
(progn (setq new-messages (vm-imap-retrieve-messages retrieve-list)))
(if (and do-retrieves retrieve-list) (progn (setq new-messages
(vm-imap-retrieve-messages retrieve-list))))
(let* ((folder-buffer (current-buffer)) (folder-name (buffer-name
folder-buffer)) (process (vm-folder-imap-process)) (imap-buffer (process-buffer
process)) (uid-validity (vm-folder-imap-uid-validity)) (imapdrop
(vm-folder-imap-maildrop-spec)) (folder (or (vm-imap-folder-for-spec imapdrop)
(vm-safe-imapdrop-string imapdrop))) new-messages (sync-data
(vm-imap-get-synchronization-data do-retrieves)) (retrieve-list (nth 0
sync-data)) (remote-expunge-list (nth 1 sync-data)) (local-expunge-list (nth 2
sync-data)) (stale-list (nth 3 sync-data))) (if save-attributes (progn (let
((mp vm-message-list) (errors 0)) (vm-inform 6 "%s: Updating attributes on the
IMAP server... " folder-name) (while mp (if (or (eq save-attributes ...)
(vm-attribute-modflag-of ...)) (condition-case nil (vm-imap-save-message-flags
process ...) (vm-imap-protocol-error ... ...))) (setq mp (cdr mp))) (if (>
errors 0) (vm-inform 3 "%s: Updating attributes on the IMAP server... %d
errors" folder-name errors) (vm-inform 6 "%s: Updating attributes on the IMAP
server... done" folder-name))))) (if retrieve-attributes (progn (let ((mp
vm-message-list) (len (length vm-message-list)) (n 0) uid m mflags) (vm-inform
6 "%s: Retrieving message attributes and labels... " folder-name) (while mp
(setq m (car mp)) (setq uid (vm-imap-uid-of m)) (if (and (equal ...
uid-validity) (vm-folder-imap-uid-msn uid)) (progn (setq mflags ...)
(vm-imap-update-message-flags m mflags t))) (setq mp (cdr mp) n (1+ n)))
(vm-inform 6 "%s: Retrieving message atrributes and labels... done"
folder-name)))) (if (and do-retrieves retrieve-list) (progn (setq new-messages
(vm-imap-retrieve-messages retrieve-list)))) (if do-local-expunges (progn
(vm-inform 6 "%s: Expunging messages in cache... " folder-name)
(vm-expunge-folder :quiet t :just-these-messages local-expunge-list) (if (and
(eq interactive t) stale-list) (if (y-or-n-p (format "%s: Found %s messages
with invalid UIDs. Expunge them? " folder-name (length stale-list)))
(vm-expunge-folder :quiet t :just-these-messages stale-list) (vm-inform 1 "%s:
They will be labelled 'stale'" folder-name) (mapc (function (lambda ... ...))
stale-list))) (vm-inform 6 "%s: Expunging messages in cache... done"
folder-name))) (if (and do-remote-expunges (if (eq do-remote-expunges (quote
all)) (setq vm-imap-messages-to-expunge remote-expunge-list)
vm-imap-messages-to-expunge)) (progn (vm-imap-expunge-remote-messages))) (setq
vm-imap-connection-mode (quote online)) new-messages)
(if (or vm-global-block-new-mail (eq vm-imap-connection-mode (quote offline))
(null (vm-establish-new-folder-imap-session interactive "general operation"
nil))) (vm-imap-server-error "Could not connect to the IMAP server") (if
do-retrieves (vm-assimilate-new-messages)) (vm-inform 6 "%s: Logging into the
IMAP server..." (buffer-name)) (let* ((folder-buffer (current-buffer))
(folder-name (buffer-name folder-buffer)) (process (vm-folder-imap-process))
(imap-buffer (process-buffer process)) (uid-validity
(vm-folder-imap-uid-validity)) (imapdrop (vm-folder-imap-maildrop-spec))
(folder (or (vm-imap-folder-for-spec imapdrop) (vm-safe-imapdrop-string
imapdrop))) new-messages (sync-data (vm-imap-get-synchronization-data
do-retrieves)) (retrieve-list (nth 0 sync-data)) (remote-expunge-list (nth 1
sync-data)) (local-expunge-list (nth 2 sync-data)) (stale-list (nth 3
sync-data))) (if save-attributes (progn (let ((mp vm-message-list) (errors 0))
(vm-inform 6 "%s: Updating attributes on the IMAP server... " folder-name)
(while mp (if (or ... ...) (condition-case nil ... ...)) (setq mp (cdr mp)))
(if (> errors 0) (vm-inform 3 "%s: Updating attributes on the IMAP server... %d
errors" folder-name errors) (vm-inform 6 "%s: Updating attributes on the IMAP
server... done" folder-name))))) (if retrieve-attributes (progn (let ((mp
vm-message-list) (len (length vm-message-list)) (n 0) uid m mflags) (vm-inform
6 "%s: Retrieving message attributes and labels... " folder-name) (while mp
(setq m (car mp)) (setq uid (vm-imap-uid-of m)) (if (and ... ...) (progn ...
...)) (setq mp (cdr mp) n (1+ n))) (vm-inform 6 "%s: Retrieving message
atrributes and labels... done" folder-name)))) (if (and do-retrieves
retrieve-list) (progn (setq new-messages (vm-imap-retrieve-messages
retrieve-list)))) (if do-local-expunges (progn (vm-inform 6 "%s: Expunging
messages in cache... " folder-name) (vm-expunge-folder :quiet t
:just-these-messages local-expunge-list) (if (and (eq interactive t)
stale-list) (if (y-or-n-p (format "%s: Found %s messages with invalid UIDs.
Expunge them? " folder-name ...)) (vm-expunge-folder :quiet t
:just-these-messages stale-list) (vm-inform 1 "%s: They will be labelled
'stale'" folder-name) (mapc (function ...) stale-list))) (vm-inform 6 "%s:
Expunging messages in cache... done" folder-name))) (if (and do-remote-expunges
(if (eq do-remote-expunges (quote all)) (setq vm-imap-messages-to-expunge
remote-expunge-list) vm-imap-messages-to-expunge)) (progn
(vm-imap-expunge-remote-messages))) (setq vm-imap-connection-mode (quote
online)) new-messages))
(progn (if vm-buffer-type-debug (setq vm-buffer-type-trail (cons (quote
synchronize) vm-buffer-type-trail))) (vm-buffer-type:set (quote folder))
(vm-imap-init-log) (vm-imap-log-tokens (list (quote synchronize)
(current-buffer) (vm-folder-imap-process))) (setq vm-buffer-type-trail nil) (if
(and do-retrieves vm-block-new-mail) (error "Can't get new mail until you save
this folder")) (if (or vm-global-block-new-mail (eq vm-imap-connection-mode
(quote offline)) (null (vm-establish-new-folder-imap-session interactive
"general operation" nil))) (vm-imap-server-error "Could not connect to the IMAP
server") (if do-retrieves (vm-assimilate-new-messages)) (vm-inform 6 "%s:
Logging into the IMAP server..." (buffer-name)) (let* ((folder-buffer
(current-buffer)) (folder-name (buffer-name folder-buffer)) (process
(vm-folder-imap-process)) (imap-buffer (process-buffer process)) (uid-validity
(vm-folder-imap-uid-validity)) (imapdrop (vm-folder-imap-maildrop-spec))
(folder (or (vm-imap-folder-for-spec imapdrop) (vm-safe-imapdrop-string
imapdrop))) new-messages (sync-data (vm-imap-get-synchronization-data
do-retrieves)) (retrieve-list (nth 0 sync-data)) (remote-expunge-list (nth 1
sync-data)) (local-expunge-list (nth 2 sync-data)) (stale-list (nth 3
sync-data))) (if save-attributes (progn (let ((mp vm-message-list) (errors 0))
(vm-inform 6 "%s: Updating attributes on the IMAP server... " folder-name)
(while mp (if ... ...) (setq mp ...)) (if (> errors 0) (vm-inform 3 "%s:
Updating attributes on the IMAP server... %d errors" folder-name errors)
(vm-inform 6 "%s: Updating attributes on the IMAP server... done"
folder-name))))) (if retrieve-attributes (progn (let ((mp vm-message-list) (len
...) (n 0) uid m mflags) (vm-inform 6 "%s: Retrieving message attributes and
labels... " folder-name) (while mp (setq m ...) (setq uid ...) (if ... ...)
(setq mp ... n ...)) (vm-inform 6 "%s: Retrieving message atrributes and
labels... done" folder-name)))) (if (and do-retrieves retrieve-list) (progn
(setq new-messages (vm-imap-retrieve-messages retrieve-list)))) (if
do-local-expunges (progn (vm-inform 6 "%s: Expunging messages in cache... "
folder-name) (vm-expunge-folder :quiet t :just-these-messages
local-expunge-list) (if (and (eq interactive t) stale-list) (if (y-or-n-p ...)
(vm-expunge-folder :quiet t :just-these-messages stale-list) (vm-inform 1 "%s:
They will be labelled 'stale'" folder-name) (mapc ... stale-list))) (vm-inform
6 "%s: Expunging messages in cache... done" folder-name))) (if (and
do-remote-expunges (if (eq do-remote-expunges (quote all)) (setq
vm-imap-messages-to-expunge remote-expunge-list) vm-imap-messages-to-expunge))
(progn (vm-imap-expunge-remote-messages))) (setq vm-imap-connection-mode (quote
online)) new-messages)))
(let* ((interactive (car (cdr (plist-member --cl-rest-- (quote
:interactive))))) (do-remote-expunges (car (cdr (plist-member --cl-rest--
(quote :do-remote-expunges))))) (do-local-expunges (car (cdr (plist-member
--cl-rest-- (quote :do-local-expunges))))) (do-retrieves (car (cdr
(plist-member --cl-rest-- (quote :do-retrieves))))) (save-attributes (car (cdr
(plist-member --cl-rest-- (quote :save-attributes))))) (retrieve-attributes
(car (cdr (plist-member --cl-rest-- (quote :retrieve-attributes)))))) (let
((--cl-keys-- --cl-rest--)) (while --cl-keys-- (cond ((memq (car --cl-keys--)
(quote (:interactive :do-remote-expunges :do-local-expunges :do-retrieves
:save-attributes :retrieve-attributes :allow-other-keys))) (setq --cl-keys--
(cdr (cdr --cl-keys--)))) ((car (cdr (memq ... --cl-rest--))) (setq --cl-keys--
nil)) (t (error "Keyword argument %s not one of (:interactive
:do-remote-expunges :do-local-expunges :do-retrieves :save-attributes
:retrieve-attributes)" (car --cl-keys--)))))) (progn (if vm-buffer-type-debug
(setq vm-buffer-type-trail (cons (quote synchronize) vm-buffer-type-trail)))
(vm-buffer-type:set (quote folder)) (vm-imap-init-log) (vm-imap-log-tokens
(list (quote synchronize) (current-buffer) (vm-folder-imap-process))) (setq
vm-buffer-type-trail nil) (if (and do-retrieves vm-block-new-mail) (error
"Can't get new mail until you save this folder")) (if (or
vm-global-block-new-mail (eq vm-imap-connection-mode (quote offline)) (null
(vm-establish-new-folder-imap-session interactive "general operation" nil)))
(vm-imap-server-error "Could not connect to the IMAP server") (if do-retrieves
(vm-assimilate-new-messages)) (vm-inform 6 "%s: Logging into the IMAP
server..." (buffer-name)) (let* ((folder-buffer (current-buffer)) (folder-name
(buffer-name folder-buffer)) (process (vm-folder-imap-process)) (imap-buffer
(process-buffer process)) (uid-validity (vm-folder-imap-uid-validity))
(imapdrop (vm-folder-imap-maildrop-spec)) (folder (or (vm-imap-folder-for-spec
imapdrop) (vm-safe-imapdrop-string imapdrop))) new-messages (sync-data
(vm-imap-get-synchronization-data do-retrieves)) (retrieve-list (nth 0
sync-data)) (remote-expunge-list (nth 1 sync-data)) (local-expunge-list (nth 2
sync-data)) (stale-list (nth 3 sync-data))) (if save-attributes (progn (let
(... ...) (vm-inform 6 "%s: Updating attributes on the IMAP server... "
folder-name) (while mp ... ...) (if ... ... ...)))) (if retrieve-attributes
(progn (let (... ... ... uid m mflags) (vm-inform 6 "%s: Retrieving message
attributes and labels... " folder-name) (while mp ... ... ... ...) (vm-inform 6
"%s: Retrieving message atrributes and labels... done" folder-name)))) (if (and
do-retrieves retrieve-list) (progn (setq new-messages
(vm-imap-retrieve-messages retrieve-list)))) (if do-local-expunges (progn
(vm-inform 6 "%s: Expunging messages in cache... " folder-name)
(vm-expunge-folder :quiet t :just-these-messages local-expunge-list) (if (and
... stale-list) (if ... ... ... ...)) (vm-inform 6 "%s: Expunging messages in
cache... done" folder-name))) (if (and do-remote-expunges (if (eq
do-remote-expunges ...) (setq vm-imap-messages-to-expunge remote-expunge-list)
vm-imap-messages-to-expunge)) (progn (vm-imap-expunge-remote-messages))) (setq
vm-imap-connection-mode (quote online)) new-messages))))
vm-imap-synchronize-folder(:interactive t :do-local-expunges t :do-retrieves
t :save-attributes t :retrieve-attributes t)
vm-get-spooled-mail(t)
vm-get-new-mail(nil)
call-interactively(vm-get-new-mail nil nil)
command-execute(vm-get-new-mail)
--
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [VM] (wrong-type-argument char-or-string-p nil) while fetching mail in IMAP folder,
Joe Malcolm <=