--- q_a/samples/inherit/readme.txt 2018/08/09 18:29:41 1.1 +++ q_a/samples/inherit/readme.txt 2018/08/09 18:30:09 1.1.1.2 @@ -1,12 +1,13 @@ - Sample: Converting Anonymous Pipes in OS/2 to Win32 +Sample: using anonymous pipe to capture child process output Summary: The sample INHERIT demonstrates how to redirect standard -output and standard error to an anonymous pipe via the -SetStdHandle Win32 API function call. It also demonstrates -how to convert the equivalent OS/2 API function calls needed -to do this with Win32 API functions. +output and standard error to an anonymous pipe using two different +techniques: passing anonymouse pipe handles to the child in the +STARTUPINFO structure, and by setting anonymous pipe handles as the +standard handles with the SetStdHandle API and having the child +process inherit them. In the sample, a child process is started whose standard output and standard error handles have been redirected to an @@ -14,14 +15,8 @@ anonymous pipe. The parent reads out of the data to both the console and to a log file specified on the command line. -More Information: - -The following is a list of the Win32 API functions used in -this sample: +Additional reference words: CloseHandle CreateProcess ReadFile - CreateFile GetLastError SetStdHandle - CreatePipe GetStdHandle WriteFile - - - + CreateFile GetLastError CreatePipe + WriteFile