summaryrefslogtreecommitdiff
path: root/lisp/dnd.el
diff options
context:
space:
mode:
authorJuanma Barranquero <lekktu@gmail.com>2010-10-08 12:14:47 +0200
committerJuanma Barranquero <lekktu@gmail.com>2010-10-08 12:14:47 +0200
commit4628bef1eea0f60e846fe6b6591725aa92952de9 (patch)
tree9d137b8e0964c0b1ebc4afb4e743e35b807d048d /lisp/dnd.el
parent24ac444fbe5d76a7cf09a62b741b9e956ab90d3e (diff)
parent2b7c934285417d2eac7a3c603231d22ce7e212d8 (diff)
downloademacs-4628bef1eea0f60e846fe6b6591725aa92952de9.tar.gz
Merge changes from emacs-23 branch.
Diffstat (limited to 'lisp/dnd.el')
-rw-r--r--lisp/dnd.el9
1 files changed, 5 insertions, 4 deletions
diff --git a/lisp/dnd.el b/lisp/dnd.el
index 7b9d0c0786c..cbbef384436 100644
--- a/lisp/dnd.el
+++ b/lisp/dnd.el
@@ -155,10 +155,11 @@ Return nil if URI is not a local file."
(let* ((decoded-f (decode-coding-string
f
(or file-name-coding-system
- default-file-name-coding-system)))
- (try-f (if (file-readable-p decoded-f) decoded-f f)))
- (when (file-readable-p try-f) try-f)))))
-
+ default-file-name-coding-system))))
+ (setq f (cond ((file-readable-p decoded-f) decoded-f)
+ ((file-readable-p f) f)
+ (t nil)))))
+ f))
(defun dnd-open-local-file (uri action)
"Open a local file.