From 37971663cf6b082c4d754c711310ba3ac1685b14 Mon Sep 17 00:00:00 2001 From: "Nathan S. Evans" Date: Tue, 16 Feb 2010 17:19:37 +0000 Subject: [PATCH] possible start for windows passing of stdin and stdout to child process --- src/util/os_priority.c | 17 +++++++++++++++++ 1 file changed, 17 insertions(+) diff --git a/src/util/os_priority.c b/src/util/os_priority.c index 4c9a449b1..2fdaa35f9 100644 --- a/src/util/os_priority.c +++ b/src/util/os_priority.c @@ -218,6 +218,10 @@ GNUNET_OS_start_process (struct GNUNET_DISK_PipeHandle *pipe_stdin, struct GNUNE char *cmd, *idx; STARTUPINFO start; PROCESS_INFORMATION proc; +#if NILS + HANDLE stdin_handle; + HANDLE stdout_handle; +#endif char *fn; int len; @@ -236,6 +240,19 @@ GNUNET_OS_start_process (struct GNUNET_DISK_PipeHandle *pipe_stdin, struct GNUNE memset (&start, 0, sizeof (start)); start.cb = sizeof (start); +#if NILS + if (pipe_stdin != NULL) + { + GNUNET_DISK_internal_file_handle_ (GNUNET_DISK_pipe_handle(pipe_stdin, GNUNET_DISK_PIPE_END_READ), &stdin_handle, sizeof (HANDLE)); + start.hStdInput = stdin_handle; + } + + if (pipe_stdout != NULL) + { + GNUNET_DISK_internal_file_handle_ (GNUNET_DISK_pipe_handle(pipe_stdout, GNUNET_DISK_PIPE_END_WRITE), &stdout_handle, sizeof (HANDLE)); + start.hStdOutput = stdout_handle; + } +#endif len = strlen (filename); if (strnicmp (filename + len - 4, ".exe", 4) == 0) fn = filename; -- 2.25.1