This is the mail archive of the libc-hacker@sourceware.cygnus.com mailing list for the glibc project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]

stdio question


Hi,
	I was just wondering if glibc's behaviour is correct for the
following situation.

	When using stdio, and after calling setvbuf() on the stream to
make it nonbuffered, if the stream is connected to a terminal then the
input will still be line buffered. Should the code perhaps do something
like:


setvbuf(..)
{

		.
		.
	case _IONBF:        /* Unbuffered.  */
		.
		.
		.
		if ( isatty ( stream->_fileno ) ) {
			/* clear ICANON flag from tty */
		}
		.
		.


	of course done in a way that fits in with glibc's structure (which
I don't know yet) and only for unix based OS's.

-eman




Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]