V4L/DVB (13807): Fix: Free device in the device registration failure case
authorManu Abraham <abraham.manu@gmail.com>
Sat, 12 Dec 2009 06:14:25 +0000 (03:14 -0300)
committerMauro Carvalho Chehab <mchehab@redhat.com>
Sun, 17 Jan 2010 13:55:44 +0000 (11:55 -0200)
Signed-off-by: Manu Abraham <manu@linuxtv.org>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
drivers/media/dvb/mantis/mantis_input.c

index 9395fcf4a453a2c9e4b7f81bf86f61c34137e29e..b27d7759788b28e32a5b696ca5f50d20772dc6e8 100644 (file)
@@ -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;
        }