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-next>] [day] [month] [year] [list]
Message-Id: <1285491584-32664-1-git-send-email-segooon@gmail.com>
Date:	Sun, 26 Sep 2010 12:59:44 +0400
From:	Vasiliy Kulikov <segooon@...il.com>
To:	kernel-janitors@...r.kernel.org
Cc:	Dmitry Torokhov <dmitry.torokhov@...il.com>,
	Cyril Chemparathy <cyril@...com>,
	Kevin Hilman <khilman@...prootsystems.com>,
	linux-input@...r.kernel.org, linux-kernel@...r.kernel.org
Subject: [PATCH] keyboard: tnetv107x: fix input_device leak

keypad_probe() calls input_free_device() on error, but keypad_remove()
doesn't.
---
 Compile tested.

 drivers/input/keyboard/tnetv107x-keypad.c |    1 +
 1 files changed, 1 insertions(+), 0 deletions(-)

diff --git a/drivers/input/keyboard/tnetv107x-keypad.c b/drivers/input/keyboard/tnetv107x-keypad.c
index b4a81eb..1ea20e1 100644
--- a/drivers/input/keyboard/tnetv107x-keypad.c
+++ b/drivers/input/keyboard/tnetv107x-keypad.c
@@ -305,6 +305,7 @@ static int __devexit keypad_remove(struct platform_device *pdev)
 	free_irq(kp->irq_press, kp);
 	free_irq(kp->irq_release, kp);
 	input_unregister_device(kp->input_dev);
+	input_free_device(kp->input_dev);
 	clk_put(kp->clk);
 	iounmap(kp->regs);
 	release_mem_region(kp->res->start, resource_size(kp->res));
-- 
1.7.0.4

--
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