]> code.delx.au - gnu-emacs/blobdiff - lisp/minibuffer.el
Merge from emacs-24; up to 2014-05-15T16:55:18Z!jan.h.d@swipnet.se
[gnu-emacs] / lisp / minibuffer.el
index 242dc7fe94e943ee9dbfbee30e218cf5877a1588..f8e39dc1529d40615c39e83d486bcc63e191391d 100644 (file)
@@ -1117,9 +1117,10 @@ If no characters can be completed, display a list of possible completions.
 If you repeat this command after it displayed such a list,
 scroll the window of possible completions."
   (interactive)
-  (completion-in-region (minibuffer-prompt-end) (point-max)
-                        minibuffer-completion-table
-                        minibuffer-completion-predicate))
+  (when (<= (minibuffer-prompt-end) (point))
+    (completion-in-region (minibuffer-prompt-end) (point-max)
+                          minibuffer-completion-table
+                          minibuffer-completion-predicate)))
 
 (defun completion--in-region-1 (beg end)
   ;; If the previous command was not this,