On Sun, Oct 09, 2016 at 08:15:27PM +0200, Stefan Brüns wrote:

> The direntlen checks were quite bogus, i.e. the loop termination used
> "len + offset == blocksize" (exact match only), and checked for a
> direntlen less than 0. The latter can never happen as the len is
> unsigned, this has been reported by Coverity, CID 153384.
> Use the same code as in search_dir for directory traversal. This code
> has the correct checks for direntlen >= sizeof(struct dirent), and
> offset < blocksize.
> Signed-off-by: Stefan Brüns <stefan.bru...@rwth-aachen.de>

Reported-by: Coverity (CID: 153383, 153384)
Reviewed-by: Tom Rini <tr...@konsulko.com>


Attachment: signature.asc
Description: Digital signature

U-Boot mailing list

Reply via email to