]> git.eshelyaron.com Git - emacs.git/commitdiff
(nnimap-retrieve-headers-progress): Use a unibyte temp buffer.
authorStefan Monnier <monnier@iro.umontreal.ca>
Wed, 12 Mar 2008 18:40:01 +0000 (18:40 +0000)
committerStefan Monnier <monnier@iro.umontreal.ca>
Wed, 12 Mar 2008 18:40:01 +0000 (18:40 +0000)
(nnimap-request-move-article): Use with-current-buffer.

lisp/gnus/ChangeLog
lisp/gnus/nnimap.el

index 21d531f59f724252bbdb45f43edfb08723600d45..f5d19f56bf923ddb39155e1ce694d2c362f5a1c3 100644 (file)
@@ -1,5 +1,8 @@
 2008-03-12  Stefan Monnier  <monnier@iro.umontreal.ca>
 
+       * 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.
index c1b7b888e9e416d964f9fb5d9919972940da49e0..18c0e23f709a5fd3adbbaa5501f1fa72ccd99fe1 100644 (file)
@@ -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))