[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Emacs-diffs] /srv/bzr/emacs/trunk r101712: (url-http-async-sentinel): C
From: |
Lars Magne Ingebrigtsen |
Subject: |
[Emacs-diffs] /srv/bzr/emacs/trunk r101712: (url-http-async-sentinel): Check that the buffer is still alive before |
Date: |
Fri, 01 Oct 2010 16:05:25 +0200 |
User-agent: |
Bazaar (2.0.3) |
------------------------------------------------------------
revno: 101712
committer: Lars Magne Ingebrigtsen <address@hidden>
branch nick: trunk
timestamp: Fri 2010-10-01 16:05:25 +0200
message:
(url-http-async-sentinel): Check that the buffer is still alive before
switching to it.
modified:
lisp/url/ChangeLog
lisp/url/url-http.el
=== modified file 'lisp/url/ChangeLog'
--- a/lisp/url/ChangeLog 2010-09-25 20:59:05 +0000
+++ b/lisp/url/ChangeLog 2010-10-01 14:05:25 +0000
@@ -1,3 +1,8 @@
+2010-10-01 Lars Magne Ingebrigtsen <address@hidden>
+
+ * url-http.el (url-http-async-sentinel): Check that the buffer is
+ still alive before switching to it.
+
2010-09-25 Julien Danjou <address@hidden>
* url-cache.el (url-cache-create-filename): Ensure no-port and
=== modified file 'lisp/url/url-http.el'
--- a/lisp/url/url-http.el 2010-07-27 02:10:05 +0000
+++ b/lisp/url/url-http.el 2010-10-01 14:05:25 +0000
@@ -1244,20 +1244,21 @@
(declare (special url-callback-arguments))
;; We are performing an asynchronous connection, and a status change
;; has occurred.
- (with-current-buffer (process-buffer proc)
- (cond
- (url-http-connection-opened
- (url-http-end-of-document-sentinel proc why))
- ((string= (substring why 0 4) "open")
- (setq url-http-connection-opened t)
- (process-send-string proc (url-http-create-request)))
- (t
- (setf (car url-callback-arguments)
- (nconc (list :error (list 'error 'connection-failed why
- :host (url-host (or url-http-proxy
url-current-object))
- :service (url-port (or url-http-proxy
url-current-object))))
- (car url-callback-arguments)))
- (url-http-activate-callback)))))
+ (when (buffer-name (process-buffer proc))
+ (with-current-buffer (process-buffer proc)
+ (cond
+ (url-http-connection-opened
+ (url-http-end-of-document-sentinel proc why))
+ ((string= (substring why 0 4) "open")
+ (setq url-http-connection-opened t)
+ (process-send-string proc (url-http-create-request)))
+ (t
+ (setf (car url-callback-arguments)
+ (nconc (list :error (list 'error 'connection-failed why
+ :host (url-host (or url-http-proxy
url-current-object))
+ :service (url-port (or url-http-proxy
url-current-object))))
+ (car url-callback-arguments)))
+ (url-http-activate-callback))))))
;; Since Emacs 19/20 does not allow you to change the
;; `after-change-functions' hook in the midst of running them, we fake
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [Emacs-diffs] /srv/bzr/emacs/trunk r101712: (url-http-async-sentinel): Check that the buffer is still alive before,
Lars Magne Ingebrigtsen <=