aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorRyan2017-05-19 11:07:57 -0400
committerNoam Postavsky2017-05-20 21:54:02 -0400
commitf422b46eb1d3c62c912ee0806486d017f5153e54 (patch)
tree14f1ee497029183f635703f78ce17b8a390b7bd8
parent547f78c813c7f792a892a2ee16664b133067f9bc (diff)
downloademacs-f422b46eb1d3c62c912ee0806486d017f5153e54.tar.gz
emacs-f422b46eb1d3c62c912ee0806486d017f5153e54.zip
Fix ido-enable-dot-prefix for empty choice (Bug#26997)
* lisp/ido.el (ido-set-matches-1): Only check first character of item if it's non-empty. Copyright-paperwork-exempt: yes
-rw-r--r--lisp/ido.el7
1 files changed, 4 insertions, 3 deletions
diff --git a/lisp/ido.el b/lisp/ido.el
index 1393d3b7107..07a5bcf7229 100644
--- a/lisp/ido.el
+++ b/lisp/ido.el
@@ -3802,9 +3802,10 @@ frame, rather than all frames, regardless of value of `ido-all-frames'."
3802 (lambda (item) 3802 (lambda (item)
3803 (let ((name (ido-name item))) 3803 (let ((name (ido-name item)))
3804 (if (and (or non-prefix-dot 3804 (if (and (or non-prefix-dot
3805 (if (= (aref ido-text 0) ?.) 3805 (and (> (length name) 0)
3806 (= (aref name 0) ?.) 3806 (if (= (aref ido-text 0) ?.)
3807 (/= (aref name 0) ?.))) 3807 (= (aref name 0) ?.)
3808 (/= (aref name 0) ?.))))
3808 (string-match re name)) 3809 (string-match re name))
3809 (cond 3810 (cond
3810 ((and (eq ido-cur-item 'buffer) 3811 ((and (eq ido-cur-item 'buffer)