aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorGlenn Morris2009-09-13 02:09:12 +0000
committerGlenn Morris2009-09-13 02:09:12 +0000
commit4f0f48dfc10906f2af1ed35afe8624670f4d7c1a (patch)
tree403d893d2fe571da6de3ce8a43ab97b3e671d41e
parent5d6ab6725966988280a28cbd0acd76996a26560e (diff)
downloademacs-4f0f48dfc10906f2af1ed35afe8624670f4d7c1a.tar.gz
emacs-4f0f48dfc10906f2af1ed35afe8624670f4d7c1a.zip
(url-file): Avoid assignment to free variable `filename'.
-rw-r--r--lisp/url/ChangeLog4
-rw-r--r--lisp/url/url-file.el10
2 files changed, 7 insertions, 7 deletions
diff --git a/lisp/url/ChangeLog b/lisp/url/ChangeLog
index eddc27b09c7..fa6ce1945b1 100644
--- a/lisp/url/ChangeLog
+++ b/lisp/url/ChangeLog
@@ -1,3 +1,7 @@
12009-09-13 Glenn Morris <rgm@gnu.org>
2
3 * url-file.el (url-file): Avoid assignment to free variable `filename'.
4
12009-09-12 Chong Yidong <cyd@stupidchicken.com> 52009-09-12 Chong Yidong <cyd@stupidchicken.com>
2 6
3 * url-methods.el (url-scheme--registering-proxy): New variable. 7 * url-methods.el (url-scheme--registering-proxy): New variable.
diff --git a/lisp/url/url-file.el b/lisp/url/url-file.el
index e58da0e302a..f0808a34872 100644
--- a/lisp/url/url-file.el
+++ b/lisp/url/url-file.el
@@ -156,13 +156,9 @@ to them."
156 (uncompressed-filename nil) 156 (uncompressed-filename nil)
157 (content-type nil) 157 (content-type nil)
158 (content-encoding nil) 158 (content-encoding nil)
159 (coding-system-for-read 'binary)) 159 (coding-system-for-read 'binary)
160 160 (filename (url-file-build-filename url)))
161 (setq filename (url-file-build-filename url)) 161 (or filename (error "File does not exist: %s" (url-recreate-url url)))
162
163 (if (not filename)
164 (error "File does not exist: %s" (url-recreate-url url)))
165
166 ;; Need to figure out the content-type from the real extension, 162 ;; Need to figure out the content-type from the real extension,
167 ;; not the compressed one. 163 ;; not the compressed one.
168 (setq uncompressed-filename (if (string-match "\\.\\(gz\\|Z\\|z\\)$" filename) 164 (setq uncompressed-filename (if (string-match "\\.\\(gz\\|Z\\|z\\)$" filename)