From: yamaoka Date: Thu, 28 Jul 2005 02:05:41 +0000 (+0000) Subject: Synch to No Gnus 200507280205. X-Git-Tag: t-gnus-6_17_4-quimby-~447 X-Git-Url: http://git.chise.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=b9e261fd8da413cda39dc0aa8702a34773c5b133;p=elisp%2Fgnus.git- Synch to No Gnus 200507280205. --- diff --git a/lisp/ChangeLog b/lisp/ChangeLog index 6c6a3ad..ee79573 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,3 +1,8 @@ +2005-07-28 Katsumi Yamaoka + + * rfc2231.el (rfc2231-parse-string): Take care that not only a + segmented parameter but also other parameters might be there. + 2005-07-27 Katsumi Yamaoka * mm-decode.el (mm-display-external): Delete temp file, directory diff --git a/lisp/rfc2231.el b/lisp/rfc2231.el index c4522ef..33ab116 100644 --- a/lisp/rfc2231.el +++ b/lisp/rfc2231.el @@ -1,6 +1,6 @@ ;;; rfc2231.el --- Functions for decoding rfc2231 headers -;; Copyright (C) 1998, 1999, 2000, 2002, 2003, 2004 +;; Copyright (C) 1998, 1999, 2000, 2002, 2003, 2004, 2005 ;; Free Software Foundation, Inc. ;; Author: Lars Magne Ingebrigtsen @@ -52,7 +52,7 @@ The list will be on the form (prev-value "") display-name mailbox c display-string parameters attribute value type subtype number encoded - prev-attribute) + prev-attribute prev-encoded) (ietf-drums-init (mail-header-remove-whitespace (mail-header-remove-comments string))) (let ((table (copy-syntax-table ietf-drums-syntax-table))) @@ -106,9 +106,14 @@ The list will be on the form ;; See if we have any previous continuations. (when (and prev-attribute (not (eq prev-attribute attribute))) - (push (cons prev-attribute prev-value) parameters) + (push (cons prev-attribute + (if prev-encoded + (rfc2231-decode-encoded-string prev-value) + prev-value)) + parameters) (setq prev-attribute nil - prev-value "")) + prev-value "" + prev-encoded nil)) (unless (eq c ?=) (error "Invalid header: %s" string)) (forward-char 1) @@ -127,7 +132,8 @@ The list will be on the form (error "Invalid header: %s" string))) (if number (setq prev-attribute attribute - prev-value (concat prev-value value)) + prev-value (concat prev-value value) + prev-encoded encoded) (push (cons attribute (if encoded (rfc2231-decode-encoded-string value) @@ -137,7 +143,7 @@ The list will be on the form ;; Take care of any final continuations. (when prev-attribute (push (cons prev-attribute - (if encoded + (if prev-encoded (rfc2231-decode-encoded-string prev-value) prev-value)) parameters))