Openwall GNU/*/Linux - a small security-enhanced Linux distro for servers
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Date: Tue, 17 Apr 2012 22:54:40 -0400
From: Rich Felker <dalias@...ifal.cx>
To: musl@...ts.openwall.com
Subject: Re: New scanf testing framework

On Tue, Apr 17, 2012 at 09:06:46PM -0400, Rich Felker wrote:
> Here's something I've been hacking around on for the past hour to test
> scanf. It's just a framework, very few tests, but the idea is that
> adding new tests is easy and they automatically test 4 variants
> (byte/wide, file/string) versions of scanf for expected
> success/failure, characters consumed, final file position, and value
> of the conversion. If anybody wants to play around with this and try
> to find some cases that break musl's new scanf code, I'd be happy to
> hear results.

I tried it with glibc, and realized it's invoking undefined behavior
by writing to the temp file with byte-oriented fwrite then performing
fwscanf (wide) to read from it. I'll send a new version (along with a
heapload of tests) in a little bit.

Rich

Powered by blists - more mailing lists

Your e-mail address:

Confused about mailing lists and their use? Read about mailing lists on Wikipedia and check out these guidelines on proper formatting of your messages.