Follow @Openwall on Twitter for new release announcements and other news
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Date: Sun, 14 Jun 2015 09:22:13 -0400
From: Rich Felker <dalias@...c.org>
To: musl@...ts.openwall.com
Subject: Re: Tests needed for byte-based C locale

On Sun, Jun 14, 2015 at 02:13:49PM +0200, Christian Neukirchen wrote:
> Rich Felker <dalias@...c.org> writes:
> 
> > Here are some basic tests I'd like to have for the byte-based C
> > locale, preferably most of them before committing the code and all
> > before a release containing it. Any help writing them (for the
> > libc-test framework) would be much appreciated. Short of that, even
> > just some quick sanity checks using existing programs (e.g. busybox
> > utils with regex/fnmatch usage) would be helpful.
> >
> > Regex & fnmatch:
> >
> > - Literals with arbitrary high bytes match.
> > - Brackets match byte values/ranges.
> 
> With GNU grep 2.21 + these patches:
> 
> $ printf 'foo\x80bar' | LANG=C grep f                  
> foo�bar
> $ printf 'foo\x80bar' | LC_ALL=C grep 'o.b'
> foo�bar
> $ printf 'foo\x80bar' | LC_ALL=C grep $'[\177-\201]' 
> foo�bar
> 
> (I guess this only tests binary detection, tho.)

Obviously this isn't comprehensive but it's nice to see a confirmation
that one of the desired usage cases is working as intended. Thanks!

Rich

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.