]> code.delx.au - gnu-emacs/commitdiff
(repeat): Don't let execute-kbd-macro alter real-last-command.
authorRichard M. Stallman <rms@gnu.org>
Sat, 10 Feb 2001 16:33:44 +0000 (16:33 +0000)
committerRichard M. Stallman <rms@gnu.org>
Sat, 10 Feb 2001 16:33:44 +0000 (16:33 +0000)
lisp/repeat.el

index 523ee3ce964f83e7ea11ea7cb10bce4ed328b7fb..d11da6aa49863b0ceed649665f92caed72ce3f8c 100644 (file)
@@ -280,7 +280,10 @@ can be modified by the global variable `repeat-on-final-keystroke'."
        (let ((indirect (indirect-function real-last-command)))
          (if (or (stringp indirect)
                  (vectorp indirect))
-             (execute-kbd-macro real-last-command)
+             ;; Bind real-last-command so that executing the macro
+             ;; does not alter it.
+             (let ((real-last-command real-last-command))
+               (execute-kbd-macro real-last-command))
            (call-interactively real-last-command)))))
     (when repeat-repeat-char
       ;; A simple recursion here gets into trouble with max-lisp-eval-depth