Include <config.h> instead of "config.h".
[bpt/emacs.git] / src / macros.c
index 64e9177..540792e 100644 (file)
@@ -1,5 +1,5 @@
 /* Keyboard macros.
-   Copyright (C) 1985, 1986, 1992 Free Software Foundation, Inc.
+   Copyright (C) 1985, 1986, 1993 Free Software Foundation, Inc.
 
 This file is part of GNU Emacs.
 
@@ -18,7 +18,7 @@ along with GNU Emacs; see the file COPYING.  If not, write to
 the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.  */
 
 
-#include "config.h"
+#include <config.h>
 #include "lisp.h"
 #include "macros.h"
 #include "commands.h"
@@ -106,8 +106,8 @@ An argument of zero means repeat until error.")
     {
       defining_kbd_macro = 0;
       update_mode_lines++;
-      Vlast_kbd_macro = make_array (kbd_macro_end - kbd_macro_buffer,
-                                   kbd_macro_buffer);
+      Vlast_kbd_macro = make_event_array (kbd_macro_end - kbd_macro_buffer,
+                                         kbd_macro_buffer);
       message("Keyboard macro defined");
     }
 
@@ -115,8 +115,8 @@ An argument of zero means repeat until error.")
     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 @@ COUNT is a repeat count, or nil for once, or 0 for infinite loop.")
       executing_macro_index = 0;
 
       command_loop_1 ();
+
+      QUIT;
     }
   while (--repeat && (XTYPE (Vexecuting_macro) == Lisp_String
                      || XTYPE (Vexecuting_macro) == Lisp_Vector));