changeset 1682:af0995b9b142

* macros.c (Fend_kbd_macro): Don't use XFASTINT to check if arg is negative; XFASTINT only works on values known to be positive. (Fexecute_kbd_macro): Check QUIT in the repetition loop. If the macro is null, no characters are actually being read, so this matters.
author Jim Blandy <jimb@redhat.com>
date Sat, 12 Dec 1992 15:35:41 +0000
parents a03b87a92614
children a0a41de51400
files src/macros.c
diffstat 1 files changed, 4 insertions(+), 2 deletions(-) [+]
line wrap: on
line diff
--- a/src/macros.c	Sat Dec 12 15:35:12 1992 +0000
+++ b/src/macros.c	Sat Dec 12 15:35:41 1992 +0000
@@ -115,8 +115,8 @@
     Fexecute_kbd_macro (Vlast_kbd_macro, arg);
   else
     {
-      XFASTINT (arg)--;
-      if (XFASTINT (arg) > 0)
+      XSETINT (arg, XINT (arg)-1);
+      if (XINT (arg) > 0)
 	Fexecute_kbd_macro (Vlast_kbd_macro, arg);
     }
   return Qnil;
@@ -217,6 +217,8 @@
       executing_macro_index = 0;
 
       command_loop_1 ();
+
+      QUIT;
     }
   while (--repeat && (XTYPE (Vexecuting_macro) == Lisp_String
 		      || XTYPE (Vexecuting_macro) == Lisp_Vector));