Re: [repost] Patch to make cpdup's stdout unbuffered

看板DFBSD_submit作者時間21年前 (2004/06/09 16:01), 編輯推噓0(000)
留言0則, 0人參與, 最新討論串6/9 (看更多)
:Now, we could add a flag for every single program to write unbuffered :(linebuffered) output. Or we could do some (non-POSIX?) magic in libc :to get most of this just fixed by doing a env :LIBC_STDOUT_BUFFERING=line $program or whatever... : :opinions about this? : :cheers : simon Say what? No, we are not hacking up libc to turn off buffering in some magic way. Buffering is what you want for the vast, vast majority of programs that are run from the command line. We certainly are not going to add yet another environment variable that libc has to check every time a program is started up. Just add an option to cpdup that calls setvbuf() on stdout. -Matt
文章代碼(AID): #10niE_00 (DFBSD_submit)
討論串 (同標題文章)
文章代碼(AID): #10niE_00 (DFBSD_submit)