Libxo bugs and fixes.

Alfred Perlstein bright at mu.org
Tue Jan 6 20:03:41 UTC 2015


On Jan 6, 2015, at 9:27 AM, Marcel Moolenaar wrote:

> 
>> On Dec 27, 2014, at 7:08 PM, Alfred Perlstein <bright at mu.org> wrote:
>> 
>>> 
>> OK, so I've updated https://reviews.freebsd.org/D1379 to include code to handle this.
>> 
>> Solaris and glibc have a private libc function to check if a stream is line buffered called int __flbf (FILE *stream) which returns true/false if the stream if line buffered or not.
> 
> I'm still unclear on the need or importance of adding __flbf().
> What's wrong with just calling fflush()?
> What is to be gained by only calling fflush() when the stream is
> line-buffered? Why not call fflush() when the stream is not line
> buffered?
> 
> Put differently: we have 618 instance of fflush() in the source
> tree and there has been no demand for something like __flbf()
> before that I know of. Why now? And why specifically for libxo?
> 
> If __flbf() is really important, then I'd rather see someone go
> over the source tree to add calls to it for most of those 618
> instances of fflush() at the time of its introduction. Not have
> it introduced as a side-effect of something else when it's not
> at all obvious that the side-effect was warranted.
> 
> Can you elaborate?

Nope.  the code is up, figure it out yourself.

https://github.com/splbio/freebsd/tree/ap_libxo_master/contrib/libxo

-Alfred



More information about the freebsd-arch mailing list