emacs-diffs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Emacs-diffs] Changes to emacs/lisp/url/url-http.el


From: Stefan Monnier
Subject: [Emacs-diffs] Changes to emacs/lisp/url/url-http.el
Date: Mon, 06 Mar 2006 03:17:00 +0000

Index: emacs/lisp/url/url-http.el
diff -u emacs/lisp/url/url-http.el:1.26 emacs/lisp/url/url-http.el:1.27
--- emacs/lisp/url/url-http.el:1.26     Mon Feb 20 22:21:00 2006
+++ emacs/lisp/url/url-http.el  Mon Mar  6 03:17:00 2006
@@ -121,7 +121,10 @@
          (let ((buf (generate-new-buffer " *url-http-temp*")))
            ;; `url-open-stream' needs a buffer in which to do things
            ;; like authentication.  But we use another buffer afterwards.
-           (unwind-protect (url-open-stream host buf host port)
+           (unwind-protect
+               (let ((proc (url-open-stream host buf host port)))
+                 ;; Drop the temp buffer link before killing the buffer.
+                 (set-process-buffer proc nil))
              (kill-buffer buf)))))))
 
 ;; Building an HTTP request
@@ -1109,15 +1112,15 @@
 ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
 ;;; file-name-handler stuff from here on out
 ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
-(if (not (fboundp 'symbol-value-in-buffer))
-    (defun url-http-symbol-value-in-buffer (symbol buffer
-                                                  &optional unbound-value)
+(defalias 'url-http-symbol-value-in-buffer
+  (if (fboundp 'symbol-value-in-buffer)
+      'symbol-value-in-buffer
+    (lambda (symbol buffer &optional unbound-value)
       "Return the value of SYMBOL in BUFFER, or UNBOUND-VALUE if it is 
unbound."
       (with-current-buffer buffer
-       (if (not (boundp symbol))
-           unbound-value
-         (symbol-value symbol))))
-  (defalias 'url-http-symbol-value-in-buffer 'symbol-value-in-buffer))
+        (if (not (boundp symbol))
+            unbound-value
+          (symbol-value symbol))))))
 
 (defun url-http-head (url)
   (let ((url-request-method "HEAD")




reply via email to

[Prev in Thread] Current Thread [Next in Thread]