Fix previous commit.
authorKatsumi Yamaoka <yamaoka@jpl.org>
Mon, 6 Sep 2010 05:17:47 +0000 (05:17 +0000)
committerKatsumi Yamaoka <yamaoka@jpl.org>
Mon, 6 Sep 2010 05:17:47 +0000 (05:17 +0000)
lisp/dgnushack.el

index dc256bb..a008d11 100644 (file)
@@ -377,7 +377,7 @@ dgnushack-compile."
     (defadvice directory-files (after exclude-dir-locals activate)
       "Exclude .dir-locals.el file."
       (dolist (file ad-return-value)
-       (if (string-match "/?\\.dir-locals\\.el\\'" file)
+       (if (string-match "\\(?:\\`\\|/\\)\\.dir-locals\\.el\\'" file)
            (setq ad-return-value (delete file ad-return-value)))))
     (unwind-protect
        (if (fboundp 'custom-make-dependencies)
@@ -415,7 +415,7 @@ dgnushack-compile."
     (defadvice directory-files (after exclude-dir-locals activate)
       "Exclude .dir-locals.el file."
       (dolist (file ad-return-value)
-       (if (string-match "/?\\.dir-locals\\.el\\'" file)
+       (if (string-match "\\(?:\\`\\|/\\)\\.dir-locals\\.el\\'" file)
            (setq ad-return-value (delete file ad-return-value)))))
     (unwind-protect
        (batch-update-autoloads)