Fix sh_keysc double free
Subsystems (3)
PATCH 1/1 Fix sh_keysc double free
Avoid double free situation from happening by removing input_free_device() after input_unregister_device(). Suggested by Dmitry Torokhov.
Signed-off-by Magnus Damm <[email protected]>
---
drivers/input/keyboard/sh_keysc.c | 1 - 1 file changed, 1 deletion(-)
drivers/input/keyboard/sh_keysc.c +0 -1
@@ -238,7 +238,6 @@ static int __devexit sh_keysc_remove(strinput_unregister_device (priv->input);free_irq (platform_get_irq (pdev,0 ), pdev); -input_free_device (priv->input);iounmap (priv->iomem_base); res =platform_get_resource (pdev,IORESOURCE_MEM ,0 );
Paul Mundt
AppliedQuoted 4 lines · Magnus Damm
Avoid double free situation from happening by removing
input_free_device()afterinput_unregister_device(). Suggested by Dmitry Torokhov.Signed-off-by Magnus Damm <[email protected]>
Applied, thanks.