summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--lisp/ido.el3
1 files changed, 3 insertions, 0 deletions
diff --git a/lisp/ido.el b/lisp/ido.el
index 2d4ac214dd1..b398e68319d 100644
--- a/lisp/ido.el
+++ b/lisp/ido.el
@@ -3579,6 +3579,9 @@ for first matching file."
(/= (aref name 0) ?.)))
(string-match re name))
(cond
+ ((and (eq ido-cur-item 'buffer)
+ (string= name (buffer-name ido-entry-buffer)))
+ (setq matches (cons item matches)))
((and full-re (string-match full-re name))
(setq full-matches (cons item full-matches)))
((and suffix-re (string-match suffix-re name))