GNU bug report logs - #10891
bug fix lisp/url/url-http.el

Previous Next

Package: emacs;

Reported by: Devon Sean McCullough <emacs-hacker2012 <at> jovi.net>

Date: Sun, 26 Feb 2012 18:03:02 UTC

Severity: normal

Done: Chong Yidong <cyd <at> gnu.org>

Bug is archived. No further changes may be made.

Full log


View this message in rfc822 format

From: Devon Sean McCullough <emacs-hacker2012 <at> jovi.net>
To: 10891 <at> debbugs.gnu.org
Subject: bug#10891: bug fix lisp/url/url-http.el
Date: Sun, 26 Feb 2012 12:21:04 -0500
(let ((url-gateway-unplugged t))
  (url-retrieve-synchronously "http://gnu.org"))

bombs
	Wrong type argument: processp, nil

should be
	Could not create connection to gnu.org:80

		Peace
			--Devon

PS: Here's the fix

--- url-http.el.~1~	2010-04-03 18:26:11.000000000 -0400
+++ url-http.el	2012-02-26 10:53:27.000000000 -0500
@@ -119,9 +120,7 @@
 	(url-http-debug "Reusing existing connection: %s:%d" host port)
       (url-http-debug "Contacting host: %s:%d" host port))
     (url-lazy-message "Contacting host: %s:%d" host port)
-    (url-http-mark-connection-as-busy
-     host port
-     (or found
+    (let ((conn (or found
          (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.
@@ -132,7 +131,9 @@
 		   ;; Drop the temp buffer link before killing the buffer.
 		   (set-process-buffer proc nil))
                  proc)
-             (kill-buffer buf)))))))
+                        (kill-buffer buf))))))
+      (and conn
+	   (url-http-mark-connection-as-busy host port conn)))))
 
 ;; Building an HTTP request
 (defun url-http-user-agent-string ()
 




This bug report was last modified 13 years and 134 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.