lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <20251121162301.GT196358@frogsfrogsfrogs>
Date: Fri, 21 Nov 2025 08:23:01 -0800
From: "Darrick J. Wong" <djwong@...nel.org>
To: Wu Guanghao <wuguanghao3@...wei.com>
Cc: tytso@....edu, linux-ext4@...r.kernel.org, adilger.kernel@...ger.ca,
	yangyun50@...wei.com
Subject: Re: [PATCH v2 1/2] fsck: fix memory leak of inst->type

On Fri, Nov 21, 2025 at 11:36:11AM +0800, Wu Guanghao wrote:
> The function free_instance() does not release i->type, resulting in a
> memory leak.
> 
> Signed-off-by: Wu Guanghao <wuguanghao3@...wei.com>

Looks good!
Reviewed-by: "Darrick J. Wong" <djwong@...nel.org>

--D

> ---
>  misc/fsck.c | 1 +
>  1 file changed, 1 insertion(+)
> 
> diff --git a/misc/fsck.c b/misc/fsck.c
> index 64d0e7c0..a06f2668 100644
> --- a/misc/fsck.c
> +++ b/misc/fsck.c
> @@ -235,6 +235,7 @@ static void parse_escape(char *word)
>  static void free_instance(struct fsck_instance *i)
>  {
>  	free(i->prog);
> +	free(i->type);
>  	free(i->device);
>  	free(i->base_device);
>  	free(i);
> -- 
> 2.27.0
> 
> 

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ