Sorry if I wasnt clear. Yes the program works on wine and works on windows .  I 'm trying to run it under wine and redirect stdin from a file to the program.  As I mentioned it only reads the first character. The "o" for open.
So I can do stdin redirect under linux - always seems to work -    something isnt working as I expected under wine. So I'm trying to find out what.

Thanks,

Jerry