| 726 | } |
| 727 | |
| 728 | void kwsysProcess_SetPipeShared(kwsysProcess* cp, int pipe, int shared) |
| 729 | { |
| 730 | if (!cp) { |
| 731 | return; |
| 732 | } |
| 733 | |
| 734 | switch (pipe) { |
| 735 | case kwsysProcess_Pipe_STDIN: |
| 736 | cp->PipeSharedSTDIN = shared ? 1 : 0; |
| 737 | break; |
| 738 | case kwsysProcess_Pipe_STDOUT: |
| 739 | cp->PipeSharedSTDOUT = shared ? 1 : 0; |
| 740 | break; |
| 741 | case kwsysProcess_Pipe_STDERR: |
| 742 | cp->PipeSharedSTDERR = shared ? 1 : 0; |
| 743 | break; |
| 744 | default: |
| 745 | return; |
| 746 | } |
| 747 | |
| 748 | /* If we are sharing the pipe, do not redirect it to a file or use a |
| 749 | native pipe. */ |
| 750 | if (shared) { |
| 751 | kwsysProcess_SetPipeFile(cp, pipe, 0); |
| 752 | kwsysProcess_SetPipeNative(cp, pipe, 0); |
| 753 | } |
| 754 | } |
| 755 | |
| 756 | void kwsysProcess_SetPipeNative(kwsysProcess* cp, int pipe, const HANDLE p[2]) |
| 757 | { |
no test coverage detected
searching dependent graphs…