[email protected] wrote:
I think reading /proc/self/fd/1 (we want to test stdout,
not stdin or stderr) is the right thing to do for the "tty" command,
As far as I know is tty specified to test the stdin so fd 0 is the
right one (fd 2 was a typo of mine, sorry). Currently Busybox and GNU
tty test stdin and glibc does readlink /proc/self/fd/0 (from strace
output).
According to man tty tests stdin.
Testing stdout is a bad idea, because most of the time, stdout will be
redirected to a pipe or file.
_______________________________________________
busybox mailing list
[email protected]
http://lists.busybox.net/mailman/listinfo/busybox