From mboxrd@z Thu Jan 1 00:00:00 1970 Message-ID: <49106a6cc36f1a2d0a749737b674bcb4@terzarima.net> To: 9fans@9fans.net From: Charles Forsyth Date: Tue, 8 Jul 2008 00:02:33 +0100 In-Reply-To: <6ACC80E1-EB30-44AF-A1CA-72B990AE6A6B@mac.com> MIME-Version: 1.0 Content-Type: text/plain; charset="US-ASCII" Content-Transfer-Encoding: 7bit Subject: Re: [9fans] APE printf difference Topicbox-Message-UUID: ddfeacd6-ead3-11e9-9d60-3106f5b1d025 "... Furthermore, characters are intended to be transmitted as a block to the host environment when ... input is requested on an unbuffered stream, or input is requested on a line buffered stream ..." that's true when a stream is established as _IONBF or _IOLBF, so if you call setvbuf, that will be true. the bit i quoted earlier dealt with how the default i/o streams stdin/stdout/stderr were configured, and that was not clear-cut, being conditional on whether the system decided they were "interactive" or not, which seemed to be implementation-dependent behaviour. now, it might turn out to be straightforward to change APE to configure the streams based on the guess made by isatty(), but that's why i asked which way APE should face by default? for import or export? Trickey's short paper on APE touches on that, and i think an earlier paper by Hume on Portability in the Research Unix environment was more explicit. in the past i relied on APE to check programs for good portability when I developed on Plan 9 but supplied the programs to others to run on Unix, VMS and Windows. perhaps now inward portability is more common, but should the older pedantry not be available at all?