aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorDave Love2002-10-09 22:51:01 +0000
committerDave Love2002-10-09 22:51:01 +0000
commitd77cab2b6343d3c86c728f85b193fe3eea297826 (patch)
treede915e4cc2f3e7416b271622645fe7d73db9234b
parent4c858c59d4ca5fb8944b35182361b889fdf36c57 (diff)
downloademacs-d77cab2b6343d3c86c728f85b193fe3eea297826.tar.gz
emacs-d77cab2b6343d3c86c728f85b193fe3eea297826.zip
(quoted-printable-encode-region): Fix non-multibyte search
for Emacs 22.
-rw-r--r--lisp/gnus/qp.el13
1 files changed, 9 insertions, 4 deletions
diff --git a/lisp/gnus/qp.el b/lisp/gnus/qp.el
index 136dbd0c9cb..6ceeb259ae1 100644
--- a/lisp/gnus/qp.el
+++ b/lisp/gnus/qp.el
@@ -1,6 +1,6 @@
1;;; qp.el --- Quoted-Printable functions 1;;; qp.el --- Quoted-Printable functions
2 2
3;; Copyright (C) 1998, 1999, 2000, 2001 Free Software Foundation, Inc. 3;; Copyright (C) 1998, 1999, 2000, 2001, 2002 Free Software Foundation, Inc.
4 4
5;; Author: Lars Magne Ingebrigtsen <larsi@gnus.org> 5;; Author: Lars Magne Ingebrigtsen <larsi@gnus.org>
6;; Keywords: mail, extensions 6;; Keywords: mail, extensions
@@ -94,9 +94,14 @@ encode lines starting with \"From\"."
94 (interactive "r") 94 (interactive "r")
95 (save-excursion 95 (save-excursion
96 (goto-char from) 96 (goto-char from)
97 ;; Fixme: This doesn't get eight-bit characters in multibyte buffers. 97 (if (fboundp 'string-to-multibyte) ; Emacs 22
98 (if (re-search-forward "[^\x0-\xff]" to t) 98 ;; Fixme: Should we allow codes in the range \x80-\xff?
99 (error "Multibyte character in QP encoding region"))) 99 (if (re-search-forward (string-to-multibyte "[^\x0-\x7f\x80-\xff]")
100 to t)
101 ;; Fixme: Improve message.
102 (error "Multibyte character in QP encoding region")
103 (if (re-search-forward "[^\x0-\xff]" to t)
104 (error "Multibyte character in QP encoding region")))))
100 (unless class 105 (unless class
101 ;; Avoid using 8bit characters. = is \075. 106 ;; Avoid using 8bit characters. = is \075.
102 ;; Equivalent to "^\000-\007\013\015-\037\200-\377=" 107 ;; Equivalent to "^\000-\007\013\015-\037\200-\377="