From: Stefan Monnier Date: Tue, 10 Jun 2008 19:10:42 +0000 (+0000) Subject: (dired-insert-directory): Don't assume Unix-style dir names. X-Git-Tag: emacs-pretest-23.0.90~4915 X-Git-Url: http://git.eshelyaron.com/gitweb/?a=commitdiff_plain;h=a7f07c365f64fb0f93e574776d3b1facdf2a7918;p=emacs.git (dired-insert-directory): Don't assume Unix-style dir names. --- diff --git a/lisp/ChangeLog b/lisp/ChangeLog index 99927a698dd..bbe2b11433d 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,5 +1,7 @@ 2008-06-10 Stefan Monnier + * dired.el (dired-insert-directory): Don't assume Unix-style dir names. + * subr.el (momentary-string-display): Use an overlay. * progmodes/compile.el (compilation-mode): diff --git a/lisp/dired.el b/lisp/dired.el index d15e32f70fb..61c3549ecc1 100644 --- a/lisp/dired.el +++ b/lisp/dired.el @@ -1044,7 +1044,9 @@ If HDR is non-nil, insert a header line with the directory name." ;; Insert text at the beginning to standardize things. (save-excursion (goto-char opoint) - (if (and (or hdr wildcard) (not (looking-at "^ /.*:$"))) + (if (and (or hdr wildcard) + (not (and (looking-at "^ \\(.*\\):$") + (file-name-absolute-p (match-string 1))))) ;; Note that dired-build-subdir-alist will replace the name ;; by its expansion, so it does not matter whether what we insert ;; here is fully expanded, but it should be absolute.