I didn't have time to read and understand that puzzle, but for further enlightenment perhaps you could look at the POSIX spec for how file descriptors and streams interact <http://www.opengroup.org/onlinepubs/009695399/functions/xsh_chap02_05.html#tag_02_05_01> and then, if glibc seems to violate that spec, please let glibc-bugs know what the problem is, by showing exactly where the violation is.
_______________________________________________ Bug-coreutils mailing list Bug-coreutils@gnu.org http://lists.gnu.org/mailman/listinfo/bug-coreutils