.emacs-my
changeset 1388 444f477bf77f
parent 1387 3dec99863e5d
child 1389 6004ef18bbe2
--- a/.emacs-my	Fri Apr 01 18:55:36 2016 +0300
+++ b/.emacs-my	Fri Apr 01 18:58:28 2016 +0300
@@ -1741,7 +1741,7 @@
       (setq field-subject (substring field-subject 0 64)))
     (setq file (concat gnus-article-save-directory "/" (format-time-string "%F_%H-%M-%S") "_" field-to "_" field-subject))
     (with-temp-file file
-      (insert-buffer buf)
+      (insert-buffer-substring buf)
       )) )
 (add-hook 'message-sent-hook 'my-message-save)
 
@@ -3096,11 +3096,11 @@
     (save-restriction
       (narrow-to-region start end)
       (goto-char (point-min))
-      (replace-string "&" "&")
+      (while (search-forward "&") (replace-match "&"))
       (goto-char (point-min))
-      (replace-string "<" "&lt;")
+      (while (search-forward "<") (replace-match "&lt;"))
       (goto-char (point-min))
-      (replace-string ">" "&gt;")
+      (while (search-forward ">") (replace-match "&gt;"))
       )))
 
 (defun my-html-charref-from-char (char)