]> code.delx.au - gnu-emacs-elpa/commitdiff
avy.el (avy-goto-line): Fix off-by-one
authorOleh Krehel <ohwoeowho@gmail.com>
Fri, 11 Sep 2015 10:24:02 +0000 (12:24 +0200)
committerOleh Krehel <ohwoeowho@gmail.com>
Fri, 11 Sep 2015 10:24:02 +0000 (12:24 +0200)
avy.el

diff --git a/avy.el b/avy.el
index ca4691662d76996320487804e56652f8feb2c90b..f46911dcddcb638411b8cd69836e6aca5c893426 100644 (file)
--- a/avy.el
+++ b/avy.el
@@ -958,7 +958,7 @@ Otherwise, forward to `goto-line' with ARG."
   (if (not (memq arg '(1 4)))
       (progn
         (goto-char (point-min))
-        (forward-line arg))
+        (forward-line (1- arg)))
     (avy-with avy-goto-line
       (let* ((avy-handler-function
               (lambda (char)