From 14a94c2b0eddaa2840f175d0f5586995bc5cd8fd Mon Sep 17 00:00:00 2001 From: Marius Gerbershagen Date: Sun, 25 Aug 2019 10:17:18 +0200 Subject: [PATCH] run-program: fix :error :output on windows The file descriptor for the error output in the parent process was set to the wrong value. --- src/c/unixsys.d | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/c/unixsys.d b/src/c/unixsys.d index af0214616..b6e52faa2 100644 --- a/src/c/unixsys.d +++ b/src/c/unixsys.d @@ -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);