Synch to No Gnus 200410290525.
[elisp/gnus.git-] / lisp / gnus-msg.el
index 5101576..f41a272 100644 (file)
@@ -1784,7 +1784,8 @@ The source file has to be in the Emacs load path."
     ;; Remove any control chars - they seem to cause trouble for some
     ;; mailers.  (Byte-compiled output from the stuff above.)
     (goto-char point)
-    (while (re-search-forward "[\000-\010\013-\037\200-\237]" nil t)
+    (while (re-search-forward (string-as-multibyte
+                              "[\000-\010\013-\037\200-\237]") nil t)
       (replace-match (format "\\%03o" (string-to-char (match-string 0)))
                     t t))
     ;; Break MIME tags purposely.
@@ -2164,8 +2165,8 @@ this is a reply."
        (setq v (with-temp-buffer
                  (insert-file-contents v)
                  (goto-char (point-max))
-                 (while (bolp)
-                   (delete-char -1))
+                 (skip-chars-backward "\n")
+                 (delete-region (+ (point) (if (bolp) 0 1)) (point-max))
                  (buffer-string))))
       (if (eq element 'import)
          (progn