[EMAIL PROTECTED] wrote:
The POSIX specification requires that the prompt be issued to stderr:-

Fair enough. Thanks for the info. What my patch essentially did was:

if (isatty(stderr)) { /* interactive */
    human=open("/dev/tty");
    fcntl(human,F_SETFD,FD_CLOEXEC);
} else {
    human=stderr;
}

/* subsequent prompts written to human rather than stderr */

Note bash does special interactive handling anyway.
For example $PS1 is only set for interactive shells.

--
Pádraig Brady - http://www.pixelbeat.org
--


_______________________________________________ Bug-coreutils mailing list Bug-coreutils@gnu.org http://lists.gnu.org/mailman/listinfo/bug-coreutils

Reply via email to