]> code.delx.au - gnu-emacs/blobdiff - lisp/mail/mail-utils.el
(mail-mode): ">" is not a supercite-style prefix
[gnu-emacs] / lisp / mail / mail-utils.el
index a5d7a6b248c6206fbc87a795e1ce68d071c3edaa..84ed13e58bb6484162442a4cd5c99734948b546c 100644 (file)
@@ -1,6 +1,6 @@
 ;;; mail-utils.el --- utility functions used both by rmail and rnews
 
-;; Copyright (C) 1985 Free Software Foundation, Inc.
+;; Copyright (C) 1985, 2001 Free Software Foundation, Inc.
 
 ;; Maintainer: FSF
 ;; Keywords: mail, news
@@ -194,7 +194,7 @@ Return a modified address list."
        (while (setq pos (string-match "\\(,\\s-*\\|\\`\\)\\([^,]*<\\([^>,:]*\\)>[^,]*\\)\\(\\s-*,\\|\\'\\)"
                                      address))
         (setq address (replace-match (match-string 3 address)
-                                     nil nil address 2)))
+                                     nil 'literal address 2)))
        address))))
 
 ; rmail-dont-reply-to-names is defined in loaddefs
@@ -223,7 +223,8 @@ Usenet paths ending in an element that matches are removed also."
                       "\\)[^,]*"))
        (case-fold-search t)
        pos epos)
-    (while (setq pos (string-match match userids pos))
+    (while (and (setq pos (string-match match userids pos))
+               (> (length userids) 0))
       ;; If there's a match, it starts at the beginning of the string,
       ;; or with `,'.  We must delete from that position to the
       ;; end of the user-id which starts at match-beginning 2.