aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorStefan Monnier <[email protected]>2008-03-12 18:40:01 +0000
committerStefan Monnier <[email protected]>2008-03-12 18:40:01 +0000
commit9c5fe825f7eda8816add3fd1a9bc6e34a3434db2 (patch)
treea72e6141171c79c3190ca468e05f5bf78831ef08
parentd4eb2b7e39d6b6ee1bee4be0b0d53a3f3202da5a (diff)
(nnimap-retrieve-headers-progress): Use a unibyte temp buffer.
(nnimap-request-move-article): Use with-current-buffer.
-rw-r--r--lisp/gnus/ChangeLog3
-rw-r--r--lisp/gnus/nnimap.el7
2 files changed, 7 insertions, 3 deletions
diff --git a/lisp/gnus/ChangeLog b/lisp/gnus/ChangeLog
index 21d531f59f..f5d19f56bf 100644
--- a/lisp/gnus/ChangeLog
+++ b/lisp/gnus/ChangeLog
@@ -1,5 +1,8 @@
2008-03-12 Stefan Monnier <[email protected]>
+ * nnimap.el (nnimap-retrieve-headers-progress): Use a unibyte temp buffer.
+ (nnimap-request-move-article): Use with-current-buffer.
+
* mm-decode.el (mm-with-part): Set the buffer to unibyte before inserting
the handle-buffer's text, so the implicit multibyte->unibyte conversion
uses string-make-unibyte rather than string-as-unibyte.
diff --git a/lisp/gnus/nnimap.el b/lisp/gnus/nnimap.el
index c1b7b888e9..18c0e23f70 100644
--- a/lisp/gnus/nnimap.el
+++ b/lisp/gnus/nnimap.el
@@ -616,7 +616,9 @@ If EXAMINE is non-nil the group is selected read-only."
lines (imap-body-lines (imap-message-body imap-current-message))
chars (imap-message-get imap-current-message 'RFC822.SIZE)))
(nnheader-insert-nov
- (with-temp-buffer
+ ;; At this stage, we only have bytes, so let's use unibyte buffers
+ ;; to make it more clear.
+ (mm-with-unibyte-buffer
(buffer-disable-undo)
(insert headers)
(let ((head (nnheader-parse-naked-head uid)))
@@ -1552,8 +1554,7 @@ function is generally only called when Gnus is shutting down."
;; request the article only when the move is NOT internal
(and (or move-is-internal
(nnimap-request-article article group server))
- (save-excursion
- (set-buffer buf)
+ (with-current-buffer buf
(buffer-disable-undo (current-buffer))
(insert-buffer-substring nntp-server-buffer)
(setq result (eval accept-form))