diff options
author | Eli Zaretskii <eliz@gnu.org> | 2010-01-22 12:23:25 +0200 |
---|---|---|
committer | Eli Zaretskii <eliz@gnu.org> | 2010-01-22 12:23:25 +0200 |
commit | 6a801864b18fb130aff93bab09c54a6d454bfc34 (patch) | |
tree | d8b88f2a19f6147bf3ad902171804f19e0c386af /lisp/jka-compr.el | |
parent | 2aff7c53068db3b7afcb9e66d8b5329f7d704dbb (diff) | |
download | emacs-6a801864b18fb130aff93bab09c54a6d454bfc34.tar.gz |
Fix bug #5447, whereby loading C:/foo.el.gz on MS-Windows would fail.
jka-compr.el (jka-compr-load): If load-file is not in load-history,
try its file-truename version.
Diffstat (limited to 'lisp/jka-compr.el')
-rw-r--r-- | lisp/jka-compr.el | 9 |
1 files changed, 8 insertions, 1 deletions
diff --git a/lisp/jka-compr.el b/lisp/jka-compr.el index 12f48bd96b1..34ffcc90a76 100644 --- a/lisp/jka-compr.el +++ b/lisp/jka-compr.el @@ -590,7 +590,14 @@ There should be no more than seven characters after the final `/'." (or nomessage (message "Loading %s...done." file)) ;; Fix up the load history to point at the right library. - (let ((l (assoc load-file load-history))) + (let ((l (or (assoc load-file load-history) + ;; On MS-Windows, if load-file is in + ;; temporary-file-directory, it will look like + ;; "c:/DOCUME~1/USER/LOCALS~1/foo", whereas + ;; readevalloop will record its truename in + ;; load-history. Therefore try truename if the + ;; original name is not in load-history. + (assoc (file-truename load-file) load-history)))) ;; Remove .gz and .elc?. (while (file-name-extension file) (setq file (file-name-sans-extension file))) |