summaryrefslogtreecommitdiff
path: root/lisp/url/url-methods.el
diff options
context:
space:
mode:
authorMiles Bader <miles@gnu.org>2006-09-18 14:16:07 +0000
committerMiles Bader <miles@gnu.org>2006-09-18 14:16:07 +0000
commit40509bab8060aa435aca2922e0528a497bf800d7 (patch)
tree9146d9c05a1f03ef0525d1692a0bdfe2598fd794 /lisp/url/url-methods.el
parent881e258a9bcf16c24be66f2d5b88e36843b1c034 (diff)
downloademacs-40509bab8060aa435aca2922e0528a497bf800d7.tar.gz
lisp/url/url-methods.el: Fix format error when http_proxy is empty string
2006-09-18 Michael Olson <mwolson@gnu.org> * url-methods.el (url-scheme-register-proxy): Handle case where getenv returns an empty string for http_proxy. This prevents an error when calling `format' later on. --This line, and those below, will be ignored-- Files to commit: lisp/url/ChangeLog lisp/url/url-methods.el This list might be incomplete or outdated if editing the log message was not invoked from an up-to-date changes buffer! Revision: emacs@sv.gnu.org/emacs--devo--0--patch-441 Creator: Michael Olson <mwolson@gnu.org>
Diffstat (limited to 'lisp/url/url-methods.el')
-rw-r--r--lisp/url/url-methods.el5
1 files changed, 5 insertions, 0 deletions
diff --git a/lisp/url/url-methods.el b/lisp/url/url-methods.el
index 6854d62af03..55166ee46f4 100644
--- a/lisp/url/url-methods.el
+++ b/lisp/url/url-methods.el
@@ -75,6 +75,11 @@
(cur-proxy (assoc scheme url-proxy-services))
(urlobj nil))
+ ;; If env-proxy is an empty string, treat it as if it were nil
+ (when (and (stringp env-proxy)
+ (string= env-proxy ""))
+ (setq env-proxy nil))
+
;; Store any proxying information - this will not overwrite an old
;; entry, so that people can still set this information in their
;; .emacs file