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: <55EEB927.1080508@kynesim.co.uk>
Date:	Tue, 08 Sep 2015 11:32:07 +0100
From:	Richard Watts <rrw@...esim.co.uk>
To:	Leon Yu <chianglungyu@...il.com>,
	Greg Kroah-Hartman <gregkh@...uxfoundation.org>,
	Jiri Slaby <jslaby@...e.com>, linux-kernel@...r.kernel.org,
	linux-serial@...r.kernel.org
Subject: Re: [PATCH] tty: don't leak cdev in tty_cdev_add()



On 07/09/15 14:08, Leon Yu wrote:
> Commit a3a10ce3429e ("Avoid usb reset crashes by making tty_io cdevs truly
> dynamic") which mixes using cdev_alloc() and cdev_init() is problematic.
> Subsequent call to cdev_init() after cdev_alloc() sets kobj release method
> from cdev_dynamic_release() to cdev_default_release() and thus makes it
> impossible to free allocated cdev.
>
> This patch also consolidates error path of cdev_add() as cdev can also leak
> here if things went wrong.
>
> Signed-off-by: Leon Yu <chianglungyu@...il.com>
> Fixes: a3a10ce3429e ("Avoid usb reset crashes by making tty_io cdevs truly dynamic")

  Oops! Apologies. Looks good to me - thank you.

Acked-by: Richard Watts <rrw@...esim.co.uk>



Richard.
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ