;;; mm-decode.el --- Functions for decoding MIME things
-;; Copyright (C) 1998, 1999, 2000, 2001, 2002, 2003, 2004, 2005, 2006,
-;; 2007, 2008, 2009, 2010, 2011 Free Software Foundation, Inc.
+;; Copyright (C) 1998-2011 Free Software Foundation, Inc.
;; Author: Lars Magne Ingebrigtsen <larsi@gnus.org>
;; MORIOKA Tomohiko <morioka@jaist.ac.jp>
("application/x-shellscript" mm-display-shell-script-inline identity)
("application/x-sh" mm-display-shell-script-inline identity)
("text/x-sh" mm-display-shell-script-inline identity)
+ ("application/javascript" mm-display-javascript-inline identity)
("text/dns" mm-display-dns-inline identity)
- ("text/org" mm-display-org-inline identity)
+ ("text/x-org" mm-display-org-inline identity)
("text/html"
mm-inline-text-html
(lambda (handle)
"application/pkcs7-mime"
;; Mutt still uses this even though it has already been withdrawn.
"application/pgp\\'"
- "text/org")
+ "text/x-org")
"A list of MIME types to be displayed automatically."
:type '(repeat regexp)
:group 'mime-display)
(setq handles (nconc (delete handle handles) (list handle))))))
;; Remove empty parts.
(dolist (handle (copy-sequence handles))
- (unless (with-current-buffer (mm-handle-buffer handle)
- (goto-char (point-min))
- (re-search-forward "[^ \t\n]" nil t))
+ (when (and (bufferp (mm-handle-buffer handle))
+ (not (with-current-buffer (mm-handle-buffer handle)
+ (goto-char (point-min))
+ (re-search-forward "[^ \t\n]" nil t))))
(setq handles (nconc (delete handle handles) (list handle)))))
(mapcar #'mm-handle-media-type handles))