On Mon, 12 Jul 2021, hiro wrote:
Date: Mon, 12 Jul 2021 20:04:23 +0200
From: hiro <[email protected]>
Reply-To: 9fans <[email protected]>
To: 9fans <[email protected]>
Subject: Re: [9fans] pngread: alloc chunk's length
it's always useful to have the testcase available, for others and for
possible future regressions
There is nothing to test, really, the length of an IDAT chunk
can't be fixed (At least you want to allocate more than 2GB...)
If a png file has a IDAT bigger than your constant, you are screwed.
You haven't noticed because the majority of encoders use small
chunks, but that doesn't mean that the code is right, is not. If
you want to test with a png file anyway, take a big image and use
some tool like
http://optipng.sourceforge.net
The resulting file will be possibly smaller, but the data stream will
be encoded in one IDAT chunk to save space and reduce the overhead
of processing numerous IDAT chunks.
But you'll just get
getchunk needed xxxxxxxx, had 1000000
------------------------------------------
9fans: 9fans
Permalink:
https://9fans.topicbox.com/groups/9fans/T4a714ed14c50767a-Mcaf942981401d70c27d13d7e
Delivery options: https://9fans.topicbox.com/groups/9fans/subscription