G
Guest
In msdn library, there is an example about "Creating a Child Process with
Redirected Input and Output".
now in my case, the child process whill use "printf" to write to its
stdout which is redirected to my pipe. but as you know, the "printf" is
buffered, so the problem is that the parent's "FeadFile" can not return when
the child has already use "printf" to write something. (!!!Note that the
child process is a third party application,I can't modify it, and the child
and parent are interactive, I must know what child had written in each step,
and I can't close the handle).
How can I solve this problem? Thank you very much.
Redirected Input and Output".
now in my case, the child process whill use "printf" to write to its
stdout which is redirected to my pipe. but as you know, the "printf" is
buffered, so the problem is that the parent's "FeadFile" can not return when
the child has already use "printf" to write something. (!!!Note that the
child process is a third party application,I can't modify it, and the child
and parent are interactive, I must know what child had written in each step,
and I can't close the handle).
How can I solve this problem? Thank you very much.