Am 18.07.2016 16:36, schrieb Chet Ramey: > On 7/18/16 10:11 AM, walter harms wrote: > >> NTL i would recommend to add one or two line about buffering into >> the ducomentation :) > > It's already documented in the right place: > > https://www.gnu.org/software/libc/manual/html_node/Stream-Buffering.html#Stream-Buffering > >
to be serious, who will look into libc documentation when ./a.out >xx 2>&1 and ./a.out 2>&1 behave differently ? They will, as i did, check if there is something special with redirections. what about: Note: be aware that when merging output (e.g. 2&>1) the sequence can differ depending on the buffering used by your programm. use setvbuf() to control buffering. see also: https://www.gnu.org/software/libc/manual/html_node/Stream-Buffering.html#Stream-Buffering or see man setvbuf adjust as you like re, wh