From 2717ded61b94ecf48decccff59a4a1fcd08f3d0b Mon Sep 17 00:00:00 2001 From: yoichi Date: Sat, 29 Apr 2006 15:00:04 +0000 Subject: [PATCH] * elmo-imap4.el (elmo-imap4-send-command): Use non-synchronizing literals. --- elmo/ChangeLog | 5 +++++ elmo/elmo-imap4.el | 22 ++++++++++++++++------ 2 files changed, 21 insertions(+), 6 deletions(-) diff --git a/elmo/ChangeLog b/elmo/ChangeLog index b2aa9fd..8464b2f 100644 --- a/elmo/ChangeLog +++ b/elmo/ChangeLog @@ -1,3 +1,8 @@ +2006-04-29 Yoichi NAKAYAMA + + * elmo-imap4.el (elmo-imap4-send-command): Use non-synchronizing + literals. + 2006-04-21 Yoichi NAKAYAMA * elmo-maildir.el (elmo-maildir-list-location): Reduce diff --git a/elmo/elmo-imap4.el b/elmo/elmo-imap4.el index 6f87018..89ced71 100644 --- a/elmo/elmo-imap4.el +++ b/elmo/elmo-imap4.el @@ -324,12 +324,22 @@ Returns a TAG string which is assigned to the COMMAND." cmdstr (elmo-imap4-format-quoted (nth 1 token))))) ((eq kind 'literal) - (setq cmdstr (concat cmdstr - (format "{%d}" (nth 2 token)))) - (process-send-string process cmdstr) - (process-send-string process "\r\n") - (setq cmdstr nil) - (elmo-imap4-accept-continue-req session) + (if (memq 'literal+ + (elmo-imap4-session-capability-internal + session)) + ;; rfc2088 + (progn + (setq cmdstr (concat cmdstr + (format "{%d+}" (nth 2 token)))) + (process-send-string process cmdstr) + (process-send-string process "\r\n") + (setq cmdstr nil)) + (setq cmdstr (concat cmdstr + (format "{%d}" (nth 2 token)))) + (process-send-string process cmdstr) + (process-send-string process "\r\n") + (setq cmdstr nil) + (elmo-imap4-accept-continue-req session)) (cond ((stringp (nth 1 token)) (setq cmdstr (nth 1 token))) ((bufferp (nth 1 token)) -- 1.7.10.4