[gnus git] branch master updated: =1= (shr-image-fetched): Avoid having point move in the article buffer.

Lars Magne Ingebrigtsen <[email protected]>
Newsgroups gmane.emacs.gnus.cvs
Message-ID <[email protected]>
       via  2d97a554d6cc6e17791e6c786fce7710f26895f2 (commit)
      from  bdb134b0b7c1fd39e95355c51ec779a71d124954 (commit)


- Log -----------------------------------------------------------------
commit 2d97a554d6cc6e17791e6c786fce7710f26895f2
Author: Lars Magne Ingebrigtsen <[email protected]>
Date:   Mon Jan 24 00:32:37 2011 +0100

    (shr-image-fetched): Avoid having point move in the article buffer.

diff --git a/lisp/ChangeLog b/lisp/ChangeLog
index c7a7c18..8abb533 100644
--- a/lisp/ChangeLog
+++ b/lisp/ChangeLog
@@ -1,5 +1,8 @@
 2011-01-23  Lars Ingebrigtsen  <[email protected]>
 
+	* shr.el (shr-image-fetched): Avoid having point move in the article
+	buffer.
+
 	* gnus-html.el (gnus-html-image-fetched): Don't kill the temporary
 	buffer after being called.  It's apparently being killed by url.el, and
 	killing it made point move to end-of-buffer in a random buffer.
diff --git a/lisp/shr.el b/lisp/shr.el
index ed30f5f..badbcaf 100644
--- a/lisp/shr.el
+++ b/lisp/shr.el
@@ -462,11 +462,12 @@ redirects somewhere else."
 	      (search-forward "\r\n\r\n" nil t))
       (let ((data (buffer-substring (point) (point-max))))
         (with-current-buffer buffer
+	  (save-excursion
           (let ((alt (buffer-substring start end))
 		(inhibit-read-only t))
 	    (delete-region start end)
 	    (goto-char start)
-	    (shr-put-image data alt)))))))
+	      (shr-put-image data alt))))))))
 
 (defun shr-put-image (data alt)
   (if (display-graphic-p)

-----------------------------------------------------------------------
Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we listed those
revisions in full, above.

Summary of changes:
 lisp/ChangeLog |    3 +++
 lisp/shr.el    |   11 ++++++-----
 2 files changed, 9 insertions(+), 5 deletions(-)

This is an automated email from the git hooks/post-receive script. It was
generated because a ref change was pushed to the repository containing
the project "Gnus Project".

The branch, master has been updated


hooks/post-receive
-- 
Gnus Project
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.