fast getline for busybox (proof of concept, untested)

Rob Landley rob at landley.net
Thu Jun 1 02:30:17 UTC 2006


On Wednesday 31 May 2006 4:55 pm, Rich Felker wrote:
> p.s. yes the fgets_embedded_nul stuff looks hackish but according to
> my reading of iso c it does not depend on any behavior outside of what
> iso c specifies for the behavior of fgets. whether there are buggy
> implementations that don't work with this, i don't know, but it seems
> doubtful since any deviation would almost have to be intentional.

Needs a comment.  It doesn't return the length so you jump through hoops to 
figure it out, but it seems like it would work...

Needs testing and it's too late to put it into 1.2, but on the whole it looks 
good.  Cool.

Rob
-- 
Never bet against the cheap plastic solution.


More information about the busybox mailing list