changeset 18824:41c3ad77f90a

(dired-find-file): Better error message for symlink to nonexistent target.
author Richard M. Stallman <rms@gnu.org>
date Wed, 16 Jul 1997 20:55:50 +0000
parents e0aed4d48398
children 36119d2da68a
files lisp/dired.el
diffstat 1 files changed, 3 insertions(+), 1 deletions(-) [+]
line wrap: on
line diff
--- a/lisp/dired.el	Wed Jul 16 14:45:30 1997 +0000
+++ b/lisp/dired.el	Wed Jul 16 20:55:50 1997 +0000
@@ -1226,7 +1226,9 @@
   (let ((file-name (file-name-sans-versions (dired-get-filename) t)))
     (if (file-exists-p file-name)
 	(find-file file-name)
-      (error "File no longer exists; type `g' to update Dired buffer"))))
+      (if (file-symlink-p file-name)
+	  (error "File is a symlink to a nonexistent target")
+	(error "File no longer exists; type `g' to update Dired buffer")))))
 
 (defun dired-mouse-find-file-other-window (event)
   "In dired, visit the file or directory name you click on."