From mboxrd@z Thu Jan 1 00:00:00 1970 X-Msuck: nntp://news.gmane.io/gmane.emacs.gnus.general/17364 Path: main.gmane.org!not-for-mail From: Shenghuo ZHU Newsgroups: gmane.emacs.gnus.general Subject: 5 bugs Date: 24 Sep 1998 01:58:43 -400 Organization: Computer Dept of U Rochester Sender: owner-ding@hpc.uh.edu Message-ID: <2nlnnanjak.fsf@zsh.cs.rochester.edu> NNTP-Posting-Host: coloc-standby.netfonds.no X-Trace: main.gmane.org 1035156078 531 80.91.224.250 (20 Oct 2002 23:21:18 GMT) X-Complaints-To: usenet@main.gmane.org NNTP-Posting-Date: Sun, 20 Oct 2002 23:21:18 +0000 (UTC) Return-Path: Original-Received: from gizmo.hpc.uh.edu (gizmo.hpc.uh.edu [129.7.102.31]) by sclp3.sclp.com (8.8.5/8.8.5) with ESMTP id BAA03416 for ; Thu, 24 Sep 1998 01:53:15 -0400 (EDT) Original-Received: from sina.hpc.uh.edu (sina.hpc.uh.edu [129.7.3.5]) by gizmo.hpc.uh.edu (8.7.6/8.7.3) with ESMTP id AAF04547; Thu, 24 Sep 1998 00:24:04 -0500 Original-Received: by sina.hpc.uh.edu (TLB v0.09a (1.20 tibbs 1996/10/09 22:03:07)); Thu, 24 Sep 1998 00:52:55 -0500 (CDT) Original-Received: from sclp3.sclp.com (root@sclp3.sclp.com [209.195.19.139]) by sina.hpc.uh.edu (8.7.3/8.7.3) with ESMTP id AAA06644 for ; Thu, 24 Sep 1998 00:52:45 -0500 (CDT) Original-Received: from cayuga.cs.rochester.edu (cayuga.cs.rochester.edu [192.5.53.209]) by sclp3.sclp.com (8.8.5/8.8.5) with SMTP id BAA03410 for ; Thu, 24 Sep 1998 01:52:37 -0400 (EDT) Original-Received: from slate.cs.rochester.edu (slate.cs.rochester.edu [192.5.53.101]) by cayuga.cs.rochester.edu (8.6.9/O) with ESMTP id BAA21644 for ; Thu, 24 Sep 1998 01:52:36 -0400 Original-Received: from brain.cs.rochester.edu (heart.cs.rochester.edu [192.5.53.109]) by slate.cs.rochester.edu (8.6.9/O) with ESMTP id BAA12148 for ; Thu, 24 Sep 1998 01:52:31 -0400 Original-Received: (from zsh@localhost) by brain.cs.rochester.edu (8.9.0/8.8.5) id BAA01543; Thu, 24 Sep 1998 01:58:43 -0400 Original-To: ding@gnus.org X-Attribution: ZSH Original-Lines: 174 User-Agent: Gnus/5.070032 (Pterodactyl Gnus v0.32) XEmacs/20.4 (Emerald) Precedence: list X-Majordomo: 1.94.jlt7 Xref: main.gmane.org gmane.emacs.gnus.general:17364 X-Report-Spam: http://spam.gmane.org/gmane.emacs.gnus.general:17364 1. MIME does not show in PGNUS 0.32 A typo in gnus-display-mime 2. When press 'v' on MIME button, there is no table. A typo in mm-interactively-view-part 3. Do not show MIME buttons of parts which have no content-type. Mails from RFC Editor does not have content-type in description. 4. Do not show MIME buttons of last part when article has no close boundary. tm-parse.el (mime/parse-multipart) of TM package will show the last part. 5. Another '\201' bug when using external base64 decoder in a language environment of GNUS Emacs 20.*. Set default-process-coding-system to nil when run external decoder. Patch attached. -- Shenghuo ------------------------------------------------------------------------ --- ChangeLog 1998/09/24 05:22:48 1.1 +++ ChangeLog 1998/09/24 05:42:45 @@ -1,3 +1,26 @@ +Thu Sep 24 01:41:03 1998 ZHU Shenghuo + + * base64.el (base64-run-command-on-region): External base64 + decoder do not use coding system + +Thu Sep 24 01:39:44 1998 ZHU Shenghuo + + * mm-decode.el (mm-interactively-view-part): Typo. + +Thu Sep 24 01:37:30 1998 ZHU Shenghuo + + * mm-decode.el (mm-dissect-multipart): Display last part when the + article has no close-delimiter + +Thu Sep 24 01:28:54 1998 ZHU Shenghuo + + * mm-decode.el (mm-dissect-buffer): Display parts which have no + content-type. + +Thu Sep 24 01:23:57 1998 ZHU Shenghuo + + * gnus-art.el (gnus-display-mime): Typo. + Thu Sep 24 02:29:57 1998 Lars Magne Ingebrigtsen * gnus.el: Pterodactyl Gnus v0.32 is released. --- base64.el 1998/09/24 05:40:29 1.1 +++ base64.el 1998/09/24 05:40:57 @@ -75,7 +75,7 @@ (defun base64-run-command-on-region (start end output-buffer command &rest arg-list) - (let ((tempfile nil) status errstring) + (let ((tempfile nil) status errstring default-process-coding-system)) (unwind-protect (progn (setq tempfile (make-temp-name "base64")) --- gnus-art.el 1998/09/24 05:21:08 1.1 +++ gnus-art.el 1998/09/24 05:22:38 @@ -2253,29 +2253,29 @@ (mail-narrow-to-head) (when (setq ct (mail-fetch-field "content-type")) (setq ctl (condition-case () - (mail-header-parse-content-type ct) (error nil))) - (let* ((handles (mm-dissect-buffer)) - handle name type b e) - (mapcar 'mm-destroy-part gnus-article-mime-handles) - (setq gnus-article-mime-handles handles) - (when handles - (goto-char (point-min)) - (search-forward "\n\n" nil t) - (delete-region (point) (point-max)) - (if (not (equal (car ctl) "multipart/alternative")) - (while (setq handle (pop handles)) - (gnus-insert-mime-button handle) - (insert "\n\n") - (when (and (mm-automatic-display-p - (car (mm-handle-type handle))) - (or (not (mm-handle-disposition handle)) - (equal (car (mm-handle-disposition handle)) - "inline"))) - (forward-line -2) - (mm-display-part handle t) - (goto-char (point-max)))) - ;; Here we have multipart/alternative - (gnus-mime-display-alternative handles)))))))) + (mail-header-parse-content-type ct) (error nil))))) + (let* ((handles (mm-dissect-buffer)) + handle name type b e) + (mapcar 'mm-destroy-part gnus-article-mime-handles) + (setq gnus-article-mime-handles handles) + (when handles + (goto-char (point-min)) + (search-forward "\n\n" nil t) + (delete-region (point) (point-max)) + (if (not (equal (car ctl) "multipart/alternative")) + (while (setq handle (pop handles)) + (gnus-insert-mime-button handle) + (insert "\n\n") + (when (and (mm-automatic-display-p + (car (mm-handle-type handle))) + (or (not (mm-handle-disposition handle)) + (equal (car (mm-handle-disposition handle)) + "inline"))) + (forward-line -2) + (mm-display-part handle t) + (goto-char (point-max)))) + ;; Here we have multipart/alternative + (gnus-mime-display-alternative handles)))))) (defun gnus-mime-display-alternative (handles &optional preferred) (let* ((preferred (mm-preferred-alternative handles preferred)) --- mm-decode.el 1998/09/24 05:27:00 1.1 +++ mm-decode.el 1998/09/24 05:38:56 @@ -102,7 +102,8 @@ cd (mail-fetch-field "content-disposition") description (mail-fetch-field "content-description") id (mail-fetch-field "content-id")))) - (when ctl + (if (not ctl) + (mm-dissect-singlepart '("text/plain") nil no-strict-mime nil nil) (setq type (split-string (car ctl) "/")) (setq subtype (cadr type) type (pop type)) @@ -140,9 +141,16 @@ (defun mm-dissect-multipart (ctl) (goto-char (point-min)) - (let ((boundary (concat "\n--" (mail-content-type-get ctl 'boundary))) - start parts end) - (while (search-forward boundary nil t) + (let* ((boundary (concat "\n--" (mail-content-type-get ctl 'boundary))) + (close-delimiter (concat boundary "--[ \t]*$")) + start parts + (end (save-excursion + (goto-char (point-max)) + (if (re-search-backward close-delimiter nil t) + (match-beginning 0) + (point-max) + )))) + (while (search-forward boundary end t) (goto-char (match-beginning 0)) (when start (save-excursion @@ -151,6 +159,11 @@ (setq parts (nconc (mm-dissect-buffer t) parts))))) (forward-line 2) (setq start (point))) + (when start + (save-excursion + (save-restriction + (narrow-to-region start (point-max)) + (setq parts (nconc (mm-dissect-buffer t) parts))))) (nreverse parts))) (defun mm-copy-to-buffer () @@ -367,7 +380,7 @@ "Display HANDLE using METHOD." (let* ((type (car (mm-handle-type handle))) (methods - (mapcar (lambda (i) (list (cdr (assoc "viewer" i)))) + (mapcar (lambda (i) (list (cdr (assoc 'viewer i)))) (mailcap-mime-info type 'all))) (method (completing-read "Viewer: " methods))) (mm-display-external (copy-sequence handle) method)))