From: yamaoka Date: Mon, 26 Jun 2000 11:05:31 +0000 (+0000) Subject: Sync. X-Git-Tag: t-gnus-6_14-quimby-before-AC-changed-~19 X-Git-Url: http://git.chise.org/gitweb/?a=commitdiff_plain;h=7d62399d074f3b72e2801fe43a98c2f67c932c09;p=elisp%2Fgnus.git- Sync. --- diff --git a/lisp/gnus-msg.el b/lisp/gnus-msg.el index cbf4929..41448bb 100644 --- a/lisp/gnus-msg.el +++ b/lisp/gnus-msg.el @@ -1124,7 +1124,8 @@ this is a reply." (when gcc (message-remove-header "gcc") (widen) - (setq groups (message-tokenize-header gcc " ,")) + (setq groups (message-unquote-tokens + (message-tokenize-header gcc " ,"))) ;; Copy the article over to some group(s). (while (setq group (pop groups)) (gnus-check-server diff --git a/lisp/message.el b/lisp/message.el index c341828..33ba2eb 100644 --- a/lisp/message.el +++ b/lisp/message.el @@ -1402,9 +1402,19 @@ should be sent in several parts. If it is nil, the size is unlimited." `(delete-region (progn (beginning-of-line) (point)) (progn (forward-line ,(or n 1)) (point)))) +(defun message-unquote-tokens (elems) + "Remove leading and trailing double quotes (\") from quoted strings +in list." + (mapcar (lambda (item) + (if (string-match "^\"\\(.*\\)\"$" item) + (match-string 1 item) + item)) + elems)) + (defun message-tokenize-header (header &optional separator) "Split HEADER into a list of header elements. -\",\" is used as the separator." +SEPARATOR is a string of characters to be used as separators. \",\" +is used by default." (if (not header) nil (let ((regexp (format "[%s]+" (or separator ","))) @@ -1434,7 +1444,7 @@ should be sent in several parts. If it is nil, the size is unlimited." ((and (eq (char-after) ?\)) (not quoted)) (setq paren nil)))) - (nreverse elems))))) + (nreverse elems))))) (defun message-mail-file-mbox-p (file) "Say whether FILE looks like a Unix mbox file." diff --git a/lisp/nnimap.el b/lisp/nnimap.el index 0de70fa..915fc98 100644 --- a/lisp/nnimap.el +++ b/lisp/nnimap.el @@ -37,7 +37,6 @@ ;; Todo, minor things: ;; ;; o Don't require half of Gnus -- backends should be standalone -;; o Support escape characters in `message-tokenize-header' ;; o Verify that we don't use IMAP4rev1 specific things (RFC2060 App B) ;; o Dont uid fetch 1,* in nnimap-retrive-groups (slow) ;; o Split up big fetches (1,* header especially) in smaller chunks @@ -745,8 +744,9 @@ function is generally only called when Gnus is shutting down." (deffoo nnimap-request-post (&optional server) (let ((success t)) - (dolist (mbx (message-tokenize-header - (message-fetch-field "Newsgroups")) success) + (dolist (mbx (message-unquote-tokens + (message-tokenize-header + (message-fetch-field "Newsgroups") ", ") success)) (let ((to-newsgroup (gnus-group-prefixed-name mbx gnus-command-method))) (or (gnus-active to-newsgroup) (gnus-activate-group to-newsgroup)