summaryrefslogtreecommitdiff
path: root/lisp/complete.el
diff options
context:
space:
mode:
authorRichard M. Stallman <rms@gnu.org>1998-08-13 05:05:44 +0000
committerRichard M. Stallman <rms@gnu.org>1998-08-13 05:05:44 +0000
commit06cab6db58bbb70007257887df23097e14f2706e (patch)
tree86d44e18779200f05e7d84492da6576f9e91e3d3 /lisp/complete.el
parentf868e34cd04be4030b84d8dfa32a9fd4e4f5df18 (diff)
downloademacs-06cab6db58bbb70007257887df23097e14f2706e.tar.gz
(PC-do-completion): Exclude ./ and ../ from completion.
Diffstat (limited to 'lisp/complete.el')
-rw-r--r--lisp/complete.el4
1 files changed, 3 insertions, 1 deletions
diff --git a/lisp/complete.el b/lisp/complete.el
index 4aaffa76b0c..e51a9f33402 100644
--- a/lisp/complete.el
+++ b/lisp/complete.el
@@ -562,10 +562,12 @@ of `minibuffer-completion-table' and the minibuffer contents.")
"\\|")
"\\)\\'")))
- ;; Check if there are any without an ignored extension
+ ;; Check if there are any without an ignored extension.
+ ;; Also ignore `.' and `..'.
(setq p nil)
(while p2
(or (string-match PC-ignored-regexp (car p2))
+ (string-match "\\(\\`\\|/\\)[.][.]?/?\\'" (car p2))
(setq p (cons (car p2) p)))
(setq p2 (cdr p2)))