H
Hans J?rg Brinksmeyer
Hi,
does anyone have an idea for this problem:
I use anonymous pipes to steer a console program under Win2000 with a
second 'steering aplication'. The stdin and output are redirected to
pipes.
The console application has several fgets() and fgetc() to read
strings and chars. This works very fine with the pipes.
But, there is one point where the console application uses kbhit() and
waits for a key to be hit. It seems not possible to use the pipes to
get out of the loop
while( ! kbhit() )...
I do not want to use the keyboard and I can not change the console
application, since I do not have the sources.
Is there a way to make the one program simulate this event in a way
that the console application's line while(!kbhit())... is satisfied?
Thanks a lot,
Hans J. Brinksmeyer
does anyone have an idea for this problem:
I use anonymous pipes to steer a console program under Win2000 with a
second 'steering aplication'. The stdin and output are redirected to
pipes.
The console application has several fgets() and fgetc() to read
strings and chars. This works very fine with the pipes.
But, there is one point where the console application uses kbhit() and
waits for a key to be hit. It seems not possible to use the pipes to
get out of the loop
while( ! kbhit() )...
I do not want to use the keyboard and I can not change the console
application, since I do not have the sources.
Is there a way to make the one program simulate this event in a way
that the console application's line while(!kbhit())... is satisfied?
Thanks a lot,
Hans J. Brinksmeyer