comparison src/callproc.c @ 8555:f1b1537ed3f6

(Fcall_process_region): gcpro filename_string.
author Karl Heuer <kwzh@gnu.org>
date Wed, 17 Aug 1994 21:44:49 +0000
parents 60795e826dad
children 72b312ebaa10
comparison
equal deleted inserted replaced
8554:0b44462dbbc8 8555:f1b1537ed3f6
484 If you quit, the process is killed with SIGINT, or SIGKILL if you quit again.") 484 If you quit, the process is killed with SIGINT, or SIGKILL if you quit again.")
485 (nargs, args) 485 (nargs, args)
486 int nargs; 486 int nargs;
487 register Lisp_Object *args; 487 register Lisp_Object *args;
488 { 488 {
489 register Lisp_Object filename_string, start, end; 489 struct gcpro gcpro1;
490 Lisp_Object filename_string;
491 register Lisp_Object start, end;
490 #ifdef MSDOS 492 #ifdef MSDOS
491 char *tempfile; 493 char *tempfile;
492 #else 494 #else
493 char tempfile[20]; 495 char tempfile[20];
494 #endif 496 #endif
517 #endif /* not MSDOS */ 519 #endif /* not MSDOS */
518 520
519 mktemp (tempfile); 521 mktemp (tempfile);
520 522
521 filename_string = build_string (tempfile); 523 filename_string = build_string (tempfile);
524 GCPRO1 (filename_string);
522 start = args[0]; 525 start = args[0];
523 end = args[1]; 526 end = args[1];
524 #ifdef MSDOS 527 #ifdef MSDOS
525 specbind (Qbuffer_file_type, Vbinary_process_input); 528 specbind (Qbuffer_file_type, Vbinary_process_input);
526 Fwrite_region (start, end, filename_string, Qnil, Qlambda); 529 Fwrite_region (start, end, filename_string, Qnil, Qlambda);
534 if (!NILP (args[3])) 537 if (!NILP (args[3]))
535 Fdelete_region (start, end); 538 Fdelete_region (start, end);
536 539
537 args[3] = filename_string; 540 args[3] = filename_string;
538 541
539 return unbind_to (count, Fcall_process (nargs - 2, args + 2)); 542 RETURN_UNGCPRO (unbind_to (count, Fcall_process (nargs - 2, args + 2)));
540 } 543 }
541 544
542 #ifndef VMS /* VMS version is in vmsproc.c. */ 545 #ifndef VMS /* VMS version is in vmsproc.c. */
543 546
544 /* This is the last thing run in a newly forked inferior 547 /* This is the last thing run in a newly forked inferior