diff src/msdos.c @ 99583:e84316087c93

(run_msdos_command): Don't call dos_ttcooked, dos_ttraw, and bright_bg if noninteractive is non-zero.
author Eli Zaretskii <eliz@gnu.org>
date Sat, 15 Nov 2008 16:19:28 +0000
parents c5c8f07bc47c
children e038c1a8307c
line wrap: on
line diff
--- a/src/msdos.c	Sat Nov 15 15:41:56 2008 +0000
+++ b/src/msdos.c	Sat Nov 15 16:19:28 2008 +0000
@@ -4749,7 +4749,8 @@
   if (have_mouse > 0)
     mouse_get_xy (&x, &y);
 
-  dos_ttcooked ();	/* do it here while 0 = stdin */
+  if (!noninteractive)
+    dos_ttcooked ();	/* do it here while 0 = stdin */
 
   dup2 (tempin, 0);
   dup2 (tempout, 1);
@@ -4809,7 +4810,8 @@
   emacs_close (outbak);
   emacs_close (errbak);
 
-  dos_ttraw (CURTTY ());
+  if (!noninteractive)
+    dos_ttraw (CURTTY ());
   if (have_mouse > 0)
     {
       mouse_init ();
@@ -4819,7 +4821,8 @@
   /* Some programs might change the meaning of the highest bit of the
      text attribute byte, so we get blinking characters instead of the
      bright background colors.  Restore that.  */
-  bright_bg ();
+  if (!noninteractive)
+    bright_bg ();
 
  done:
   chdir (oldwd);