I'm trying to Read the results from a perl.exe into my
app using createpipe, CreateProcess and then looping
through ReadFile until no more chars are left in the
stdIn Pipe.
Data is being returned fine, however on the final
ReadFile when it should return 0 for bytesread, It just
HANGS as if its waiting for more data.
Any ideas on how I can solve this problem will be most
welcomed,
Regards
James Jones
Ja...@Starlots.com
It's not exactly the same thing, but I solved a problem with ReadFile
hanging when there's no data to begin with by using PeekNamedPipe
(which also works with anon pipes) to determine if anything remained
to be read before calling ReadFile. Offhand seems like it should work
in your case too.
-Tom
MVP - Visual Basic
(please post replies to the newsgroup)