[U-Boot] [U-Boot, v5, 10/16] ext4: Avoid out-of-bounds access of block bitmap

Tom Rini trini at konsulko.com
Fri Sep 23 21:57:25 CEST 2016


On Tue, Sep 06, 2016 at 04:36:50AM +0200, Stefan Brüns wrote:

> If the blocksize is 1024, count is initialized with 1. Incrementing count
> by 8 will never match (count == fs->blksz * 8), and ptr may be
> incremented beyond the buffer end if the bitmap is filled. Add the
> startblock offset after the loop.
> 
> Remove the second loop, as only the first iteration will be done.
> 
> Signed-off-by: Stefan Brüns <stefan.bruens at rwth-aachen.de>
> Reviewed-by: Lukasz Majewski <l.majewski at samsung.com>

Applied to u-boot/master, thanks!

-- 
Tom
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 819 bytes
Desc: Digital signature
URL: <http://lists.denx.de/pipermail/u-boot/attachments/20160923/5deefb80/attachment.sig>


More information about the U-Boot mailing list