lkml.org 
[lkml]   [2021]   [Jul]   [18]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
SubjectRe: [PATCH] mtd: devices: mchp48l640: Fix memory leak on cmd
From
Date
Hello Colin,

On 12.07.21 16:52, Colin King wrote:
> From: Colin Ian King <colin.king@canonical.com>
>
> The allocation for cmd is not being kfree'd on the return leading to
> a memory leak. Fix this by kfree'ing it.
>
> Addresses-Coverity: ("Resource leak")
> Fixes: 88d125026753 ("mtd: devices: add support for microchip 48l640 EERAM")
> Signed-off-by: Colin Ian King <colin.king@canonical.com>
> ---
> drivers/mtd/devices/mchp48l640.c | 1 +
> 1 file changed, 1 insertion(+)

Good catch, thanks!

Reviewed-by: Heiko Schocher <hs@denx.de>

bye,
Heiko
--
DENX Software Engineering GmbH, Managing Director: Wolfgang Denk
HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany
Phone: +49-8142-66989-52 Fax: +49-8142-66989-80 Email: hs@denx.de

\
 
 \ /
  Last update: 2021-07-19 05:46    [W:0.038 / U:0.048 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site