summaryrefslogtreecommitdiff
path: root/lisp/international/utf-7.el
diff options
context:
space:
mode:
authorStefan Monnier <monnier@iro.umontreal.ca>2008-02-28 19:43:51 +0000
committerStefan Monnier <monnier@iro.umontreal.ca>2008-02-28 19:43:51 +0000
commit13dbab28a0b0b010272b8597150701a3db454ff9 (patch)
treeaea55c90d6a96a8a84dd8be4729fd7cbab90ffda /lisp/international/utf-7.el
parent0aa5691d5ef20e6fcc5ce40d0e85e596c92162ab (diff)
downloademacs-13dbab28a0b0b010272b8597150701a3db454ff9.tar.gz
(utf-7-encode): Never skip the trailing - for the `imap' variant.
Diffstat (limited to 'lisp/international/utf-7.el')
-rw-r--r--lisp/international/utf-7.el4
1 files changed, 3 insertions, 1 deletions
diff --git a/lisp/international/utf-7.el b/lisp/international/utf-7.el
index 4076c574266..f523c311787 100644
--- a/lisp/international/utf-7.el
+++ b/lisp/international/utf-7.el
@@ -126,7 +126,9 @@ ESC and SKIP-CHARS are adjusted for the normal and IMAP versions."
;; consistent with iconv, at least regarding `='.
(skip-chars-forward "^= \t\n")
(delete-region (point) (point-max))))
- (unless (eobp)
+ ;; RFC2060 stipulates that all names MUST end in US-ASCII (i.e.
+ ;; a name that ends with a Unicode octet MUST end with a "-").
+ (if (or imap (not (eobp)))
(insert ?-)))))
nil))