Re: getline & getline_safe

Derek Robert Price <[email protected]>
Newsgroups gmane.comp.lib.gnulib.bugs,gmane.comp.version-control.cvs.bugs
Organization Ximbiot <http://ximbiot.com>
Message-ID <[email protected]>
Derek Robert Price wrote:

> In any case, I was almost done with a very similar solution to yours 
> when I got your email, so I merged my changes, carried through some of 
> yours, and fixed a few bugs in my original patch which also existed in 
> yours (I checked my version into CVS last night and it went out to be 
> tested on some dozen platforms with mixed results - at this point, at 
> least most of the bugs should have been fixed though not all platforms 
> have checked in for the second time).
>
> I also installed getndelim2 as a separate module since Jim Meyering 
> requested it.


Oh, I also switched limit to be a limit on the number of characters to 
read rather than the amount of memory to allocate.  It is easy enough 
for the caller to determine limit from linesize if her intentions are to 
limit memory and this way there are never any bytes thrown away.  
Limiting the number of bytes read also simplified getndelim2() considerably.

Derek

-- 
                *8^)

Email: [email protected]

Get CVS support at <http://ximbiot.com>!
--
He who dies with the most toys, is, nonetheless, still dead.
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.