Skip site navigation (1)Skip section navigation (2)
Date:      Mon, 8 Mar 2010 23:29:19 +0300
From:      Andrey Chernov <ache@nagual.pp.ru>
To:        Bruce Evans <brde@optusnet.com.au>, Jaakko Heinonen <jh@FreeBSD.ORG>, src-committers@FreeBSD.ORG, svn-src-all@FreeBSD.ORG, svn-src-head@FreeBSD.ORG
Subject:   Re: svn commit: r204803 - head/usr.bin/uniq
Message-ID:  <20100308202919.GA67990@nagual.pp.ru>
In-Reply-To: <20100308195123.GA10624@zim.MIT.EDU>
References:  <201003061921.o26JLv36014114@svn.freebsd.org> <20100307104626.GA9015@a91-153-117-195.elisa-laajakaista.fi> <20100308015926.O11669@delplex.bde.org> <20100307183139.GA50243@nagual.pp.ru> <20100307201027.GA51623@nagual.pp.ru> <20100308195123.GA10624@zim.MIT.EDU>

next in thread | previous in thread | raw e-mail | index | archive | help
On Mon, Mar 08, 2010 at 02:51:23PM -0500, David Schultz wrote:
> You can actually just call getline() rather than reinventing the
> wheel.  

See just committed version. I use getline(3) (POSIX one).

> I've had a wide character version of getline() ready to
> commit for some time (I just need to find the time to do it), so
> you won't need to call mbstowcs() as a separate step.

It does not help, since wide version will fail on EILSEQ with sync lost,
as getwc() does. Initially I was thinking about ftell+fseek back, but not 
all files are seekable.

BTW, I plan to made similar changes to comm(1) too, it suffer from the 
same EILSEQ problem.

-- 
http://ache.pp.ru/



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20100308202919.GA67990>