aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJorgen Schaefer2013-10-03 22:12:16 -0400
committerStefan Monnier2013-10-03 22:12:16 -0400
commit6cad7ba3b95684866a6dbcd56bb4d7cdde91bce4 (patch)
tree418e1e508b215d904045659929588e058a13ca29
parent75273afb0de9e8a8eede149f3afdba0d855e7b5a (diff)
downloademacs-6cad7ba3b95684866a6dbcd56bb4d7cdde91bce4.tar.gz
emacs-6cad7ba3b95684866a6dbcd56bb4d7cdde91bce4.zip
* lisp/minibuffer.el (completion--replace): Be careful that `end' might be
a marker.
-rw-r--r--lisp/ChangeLog5
-rw-r--r--lisp/minibuffer.el5
2 files changed, 8 insertions, 2 deletions
diff --git a/lisp/ChangeLog b/lisp/ChangeLog
index 936f2b1f8e5..b2bd9900ac3 100644
--- a/lisp/ChangeLog
+++ b/lisp/ChangeLog
@@ -1,3 +1,8 @@
12013-10-04 Jorgen Schaefer <forcer@forcix.cx>
2
3 * minibuffer.el (completion--replace): Be careful that `end' might be
4 a marker.
5
12013-10-03 Daiki Ueno <ueno@gnu.org> 62013-10-03 Daiki Ueno <ueno@gnu.org>
2 7
3 Add support for package signature checking. 8 Add support for package signature checking.
diff --git a/lisp/minibuffer.el b/lisp/minibuffer.el
index e588964a65b..0940e90212e 100644
--- a/lisp/minibuffer.el
+++ b/lisp/minibuffer.el
@@ -873,8 +873,9 @@ Moves point to the end of the new text."
873 (setq end (- end suffix-len)) 873 (setq end (- end suffix-len))
874 (setq newtext (substring newtext 0 (- suffix-len)))) 874 (setq newtext (substring newtext 0 (- suffix-len))))
875 (goto-char beg) 875 (goto-char beg)
876 (insert-and-inherit newtext) 876 (let ((length (- end beg))) ;Read `end' before we insert the text.
877 (delete-region (point) (+ (point) (- end beg))) 877 (insert-and-inherit newtext)
878 (delete-region (point) (+ (point) length)))
878 (forward-char suffix-len))) 879 (forward-char suffix-len)))
879 880
880(defcustom completion-cycle-threshold nil 881(defcustom completion-cycle-threshold nil