|
Message-ID: <CAPLrYEQJvKi18qptLVRV-FqMw93xUOGtWo+1tYFpEPJgWL5KkQ@mail.gmail.com> Date: Sun, 12 Aug 2012 14:52:19 +0200 From: Daniel Cegiełka <daniel.cegielka@...il.com> To: musl@...ts.openwall.com Subject: Re: Priorities for next release? 2012/8/11 Rich Felker <dalias@...ifal.cx>: > On Sat, Aug 11, 2012 at 04:51:28PM -0400, Rich Felker wrote: >> > I'm sending fgetln.c (+my diff), but please check it... >> > btw. it based on /usr.bin/make/util.c from OpenBSD: >> >> If we add fgetln, I'd like a much higher quality of implementation. >> It's not clear from the past documentation I've read for this function >> that it's allowed to use a shared static buffer for all FILEs, and >> even if it were, I find that really ugly. Instead, simply returning a >> pointer into the FILE's buffer when the whole line is already present >> in the buffer, and otherwise allocating a FILE-local buffer for it, >> would be a lot nicer. fclose could then check the FILE-local pointer >> and free if it it was allocated. > > See attached. Does it work okay? > > Rich Thank you! And I see that is already in the repo... so I built a new version (with new memcpy). btw. I see that musl supports getdents(), but it is not visible in dirent.h. Daniel
Powered by blists - more mailing lists
Confused about mailing lists and their use? Read about mailing lists on Wikipedia and check out these guidelines on proper formatting of your messages.