aboutsummaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorKarl Heuer1995-12-13 02:26:07 +0000
committerKarl Heuer1995-12-13 02:26:07 +0000
commit67d98d33afce21cbae01cf1a9ac43492b1e74049 (patch)
treecceba2494a3bd4a83466b4f327f74060c988291e /src
parentc9adab2527a57f9d2ca4bc85bffe2c92f368c22f (diff)
downloademacs-67d98d33afce21cbae01cf1a9ac43492b1e74049.tar.gz
emacs-67d98d33afce21cbae01cf1a9ac43492b1e74049.zip
(run_msdos_command): Support redirection of stderr.
Diffstat (limited to 'src')
-rw-r--r--src/msdos.c9
1 files changed, 5 insertions, 4 deletions
diff --git a/src/msdos.c b/src/msdos.c
index cff45ca3f94..075f8bfa50b 100644
--- a/src/msdos.c
+++ b/src/msdos.c
@@ -2196,12 +2196,13 @@ dos_ttcooked ()
2196 2196
2197 2197
2198/* Run command as specified by ARGV in directory DIR. 2198/* Run command as specified by ARGV in directory DIR.
2199 The command is run with input from TEMPIN and output to file TEMPOUT. */ 2199 The command is run with input from TEMPIN, output to
2200 file TEMPOUT and stderr to TEMPERR. */
2200int 2201int
2201run_msdos_command (argv, dir, tempin, tempout) 2202run_msdos_command (argv, dir, tempin, tempout, temperr)
2202 unsigned char **argv; 2203 unsigned char **argv;
2203 Lisp_Object dir; 2204 Lisp_Object dir;
2204 int tempin, tempout; 2205 int tempin, tempout, temperr;
2205{ 2206{
2206 char *saveargv1, *saveargv2, **envv; 2207 char *saveargv1, *saveargv2, **envv;
2207 char oldwd[MAXPATHLEN + 1]; /* Fixed size is safe on MSDOS. */ 2208 char oldwd[MAXPATHLEN + 1]; /* Fixed size is safe on MSDOS. */
@@ -2272,7 +2273,7 @@ run_msdos_command (argv, dir, tempin, tempout)
2272 2273
2273 dup2 (tempin, 0); 2274 dup2 (tempin, 0);
2274 dup2 (tempout, 1); 2275 dup2 (tempout, 1);
2275 dup2 (tempout, 2); 2276 dup2 (temperr, 2);
2276 2277
2277 result = spawnve (P_WAIT, argv[0], argv, envv); 2278 result = spawnve (P_WAIT, argv[0], argv, envv);
2278 2279