Check if we read something when emptying stdin queue
In some cases (looking at you s390x again) select may report there's something
on stdin while there's nothing and stdin.read(1) returns nothing. If that
happens, we are good to stop reading from stdin because there's nothing queued.
Related: rhbz#1162702