MCPcopy Create free account
hub / github.com/Kitware/CMake / kwsysProcess_SetPipeNative

Function kwsysProcess_SetPipeNative

Source/kwsys/ProcessUNIX.c:588–625  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

586}
587
588void kwsysProcess_SetPipeNative(kwsysProcess* cp, int prPipe, int const p[2])
589{
590 int* pPipeNative = 0;
591
592 if (!cp) {
593 return;
594 }
595
596 switch (prPipe) {
597 case kwsysProcess_Pipe_STDIN:
598 pPipeNative = cp->PipeNativeSTDIN;
599 break;
600 case kwsysProcess_Pipe_STDOUT:
601 pPipeNative = cp->PipeNativeSTDOUT;
602 break;
603 case kwsysProcess_Pipe_STDERR:
604 pPipeNative = cp->PipeNativeSTDERR;
605 break;
606 default:
607 return;
608 }
609
610 /* Copy the native pipe descriptors provided. */
611 if (p) {
612 pPipeNative[0] = p[0];
613 pPipeNative[1] = p[1];
614 } else {
615 pPipeNative[0] = -1;
616 pPipeNative[1] = -1;
617 }
618
619 /* If we are using a native pipe, do not share it or redirect it to
620 a file. */
621 if (p) {
622 kwsysProcess_SetPipeFile(cp, prPipe, 0);
623 kwsysProcess_SetPipeShared(cp, prPipe, 0);
624 }
625}
626
627int kwsysProcess_GetOption(kwsysProcess* cp, int optionId)
628{

Callers 2

kwsysProcess_SetPipeFileFunction · 0.70

Calls 2

kwsysProcess_SetPipeFileFunction · 0.70

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…