Эх сурвалжийг харах

V4L/DVB (13807): Fix: Free device in the device registration failure case

Signed-off-by: Manu Abraham <manu@linuxtv.org>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
Manu Abraham 15 жил өмнө
parent
commit
1e42dc7890

+ 1 - 0
drivers/media/dvb/mantis/mantis_input.c

@@ -129,6 +129,7 @@ int mantis_input_init(struct mantis_pci *mantis)
 	err = input_register_device(rc);
 	if (err) {
 		dprintk(MANTIS_ERROR, 1, "IR device registration failed, ret = %d", err);
+		input_free_device(rc);
 		return -ENODEV;
 	}