浏览代码

Input: omap-keypad - fix error handling code

According to the previous error handling code, it is likely that 'goto
err_free_keymap' is expected here in order to avoid a memory leak in error
handling path.

Signed-off-by: Christophe JAILLET <christophe.jaillet@wanadoo.fr>
Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com>
Christophe JAILLET 8 年之前
父节点
当前提交
9bb9dc1359
共有 1 个文件被更改,包括 1 次插入1 次删除
  1. 1 1
      drivers/input/keyboard/omap4-keypad.c

+ 1 - 1
drivers/input/keyboard/omap4-keypad.c

@@ -358,7 +358,7 @@ static int omap4_keypad_probe(struct platform_device *pdev)
 				     "omap4-keypad", keypad_data);
 				     "omap4-keypad", keypad_data);
 	if (error) {
 	if (error) {
 		dev_err(&pdev->dev, "failed to register interrupt\n");
 		dev_err(&pdev->dev, "failed to register interrupt\n");
-		goto err_free_input;
+		goto err_free_keymap;
 	}
 	}
 
 
 	device_init_wakeup(&pdev->dev, true);
 	device_init_wakeup(&pdev->dev, true);