hi,
i'd like to read stdin like this:
But if no data is written to stdin (by another process) then it hangs...
How can i determine if there is anything to read or not?
in.atEnd() does not work, in.bytesAvailable() does not work... they always return 0, even if the other process has written data to stdin.
So before calling in.readLine() i would like to know if there is data available, because i want QString line to be empty, if stdin is empty.
Thanks!
Oh and it is win32, i've read QSocketNotifier can be used in linux to notify if data has been written to stdin...