* gnus.el (ham-process-destination): added new parameter for
[gnus] / lisp / mml.el
index 09befee..27c9eb6 100644 (file)
@@ -1,5 +1,5 @@
 ;;; mml.el --- A package for parsing and validating MML documents
-;; Copyright (C) 1998, 1999, 2000, 2001, 2002 Free Software Foundation, Inc.
+;; Copyright (C) 1998, 1999, 2000, 2001, 2002, 2003 Free Software Foundation, Inc.
 
 ;; Author: Lars Magne Ingebrigtsen <larsi@gnus.org>
 ;; This file is part of GNU Emacs.
@@ -939,7 +939,9 @@ See Info node `(emacs-mime)Composing'.
       (when value
        ;; Quote VALUE if it contains suspicious characters.
        (when (string-match "[\"'\\~/*;() \t\n]" value)
-         (setq value (prin1-to-string value)))
+         (setq value (with-output-to-string
+                       (let (print-escape-nonascii)
+                         (prin1 value)))))
        (insert (format " %s=%s" key value)))))
   (insert ">\n"))
 
@@ -1007,15 +1009,15 @@ TYPE is the MIME type to use."
   (mml-insert-tag 'part 'type type 'disposition "inline")
   (forward-line -1))
 
-(defun mml-preview-insert-mft ()
+(defun mml-preview-insert-mail-followup-to ()
   "Insert a Mail-Followup-To header before previewing an article.
 Should be adopted if code in `message-send-mail' is changed."
   (when (and (message-mail-p)
             (message-subscribed-p)
             (not (mail-fetch-field "mail-followup-to"))
-            (message-make-mft))
+            (message-make-mail-followup-to))
     (message-position-on-field "Mail-Followup-To" "X-Draft-From")
-    (insert (message-make-mft))))
+    (insert (message-make-mail-followup-to))))
 
 (defun mml-preview (&optional raw)
   "Display current buffer with Gnus, in a new buffer.
@@ -1037,7 +1039,7 @@ If RAW, don't highlight the article."
                                   "*MIME preview of ") (buffer-name))))
       (erase-buffer)
       (insert-buffer buf)
-      (mml-preview-insert-mft)
+      (mml-preview-insert-mail-followup-to)
       (let ((message-deletable-headers (if (message-news-p)
                                           nil
                                         message-deletable-headers)))