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] [thread-next>] [day] [month] [year] [list]
Date:   Fri, 12 Apr 2019 11:38:35 +0300
From:   Andy Shevchenko <>
To:     Wang Hai <>
Subject: Re: [PATCH 2/2] net-sysfs: Fix memory leak in netdev_register_kobject

On Fri, Apr 12, 2019 at 04:36:34PM -0400, Wang Hai wrote:

> +error_register:
> +	device_del(dev);
> +error_device_add:
> +	kfree_const(dev->;
>  	return error;

When put_device() will be called on this it will go to double free (in case of
dynamically allocated dev->

Al Viro and me suggested earlier that the correct fix is to call put_device()
in a places where it is appropriate.

With Best Regards,
Andy Shevchenko

Powered by blists - more mailing lists