diff src/process.c @ 63147:9bde03db5726

* composite.c (compose_chars_in_text): * eval.c (do_autoload): * macmenu.c (set_frame_menubar): * process.c (read_process_output, exec_sentinel): * xmenu.c (set_frame_menubar): * xdisp.c (prepare_menu_bars, update_menu_bar, update_tool_bar): * w32menu.c (set_frame_menubar): Use record_unwind_save_match_data. Rename restore_match_data to restore_search_regs.
author Kim F. Storm <storm@cua.dk>
date Wed, 08 Jun 2005 22:33:36 +0000
parents f5dc34228af5
children d826c3c6df3f 173dee4e2611
line wrap: on
line diff
--- a/src/process.c	Wed Jun 08 22:32:33 2005 +0000
+++ b/src/process.c	Wed Jun 08 22:33:36 2005 +0000
@@ -4887,10 +4887,10 @@
 	{
 	  Lisp_Object tem;
 	  /* Don't clobber the CURRENT match data, either!  */
-	  tem = Fmatch_data (Qnil, Qnil);
-	  restore_match_data ();
-	  record_unwind_protect (Fset_match_data, Fmatch_data (Qnil, Qnil));
-	  Fset_match_data (tem);
+	  tem = Fmatch_data (Qnil, Qnil, Qnil);
+	  restore_search_regs ();
+	  record_unwind_save_match_data ();
+	  Fset_match_data (tem, Qt);
 	}
 
       /* For speed, if a search happens within this code,
@@ -4944,7 +4944,7 @@
 				   read_process_output_error_handler);
 
       /* If we saved the match data nonrecursively, restore it now.  */
-      restore_match_data ();
+      restore_search_regs ();
       running_asynch_code = outer_running_asynch_code;
 
       /* Handling the process output should not deactivate the mark.  */
@@ -6348,10 +6348,10 @@
   if (outer_running_asynch_code)
     {
       Lisp_Object tem;
-      tem = Fmatch_data (Qnil, Qnil);
-      restore_match_data ();
-      record_unwind_protect (Fset_match_data, Fmatch_data (Qnil, Qnil));
-      Fset_match_data (tem);
+      tem = Fmatch_data (Qnil, Qnil, Qnil);
+      restore_search_regs ();
+      record_unwind_save_match_data ();
+      Fset_match_data (tem, Qt);
     }
 
   /* For speed, if a search happens within this code,
@@ -6365,7 +6365,7 @@
 			     exec_sentinel_error_handler);
 
   /* If we saved the match data nonrecursively, restore it now.  */
-  restore_match_data ();
+  restore_search_regs ();
   running_asynch_code = outer_running_asynch_code;
 
   Vdeactivate_mark = odeactivate;