
13 Oct
2007
13 Oct
'07
5:29 p.m.
On 10/13/07, Henning Thielemann
Is this decision done automatically by C's standard library or must the C programmer do this manually? I couldn't find such a switch in the C program.
I believe that glibc fstat's FD 1 to find out if stdout is a terminal and sets its buffering up accordingly. The solution is to call fflush(stdout) at the correct places in the C code, or to force the buffering explicitly at the beginning of the program (see man setbuf). AGL -- Adam Langley agl@imperialviolet.org http://www.imperialviolet.org 650-283-9641