run-program: fix :error :output on windows

The file descriptor for the error output in the parent process was
set to the wrong value.
This commit is contained in:
Marius Gerbershagen 2019-08-25 10:17:18 +02:00
parent 24c93e1537
commit 14a94c2b0e

View file

@ -431,7 +431,7 @@ si_spawn_subprocess(cl_object command, cl_object argv, cl_object environ,
&child_stderr, 0, TRUE,
DUPLICATE_SAME_ACCESS);
/* Same for the parent_read and parent_error. */
parent_error = _open_osfhandle((intptr_t)child_stderr, _O_RDONLY);
parent_error = dup(parent_read);
}
else
create_descriptor(error, @':output', &child_stderr, &parent_error);