Re: [PATCH] i2c: i2c-boardinfo: fix memory leaks on devinfo

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Wed, Nov 22, 2017 at 05:52:24PM +0000, Colin King wrote:
> From: Colin Ian King <colin.king@xxxxxxxxxxxxx>
> 
> Currently when an error occurs devinfo is still allocated but is
> unused when the error exit paths break out of the for-loop. Fix
> this by kfree'ing devinfo to avoid the leak.
> 
> Detected by CoverityScan, CID#1416590 ("Resource Leak")
> 
> Fixes: 4124c4eba402 ("i2c: allow attaching IRQ resources to i2c_board_info")
> Fixes: 0daaf99d8424 ("i2c: copy device properties when using i2c_register_board_info()")
> Signed-off-by: Colin Ian King <colin.king@xxxxxxxxxxxxx>

Applied to for-current, thanks!

Attachment: signature.asc
Description: PGP signature


[Index of Archives]     [Kernel Development]     [Kernel Announce]     [Kernel Newbies]     [Linux Networking Development]     [Share Photos]     [IDE]     [Security]     [Git]     [Netfilter]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Device Mapper]

  Powered by Linux