V4L/DVB: ir: properly handle an error at input_register
PATCH 1/1 V4L/DVB: ir: properly handle an error at input_register
Be sure to rollback all init if input register fails.
Cc Maxim Levitsky <[email protected]>
Cc Jarod Wilson <[email protected]>
Signed-off-by Mauro Carvalho Chehab <[email protected]>
drivers/media/IR/ir-keytable.c +2 -0
@@ -507,6 +507,8 @@ int __ir_input_register(struct input_dev *input_dev, } rc =ir_register_input (input_dev); +if (rc <0 ) + goto out_event; IR_dprintk(1, "Registered input device on %s for %s remote%s.\n", driver_name, rc_tab->name,
Quoted 5 lines · Mauro Carvalho Chehab
Be sure to rollback all init if input register fails.
Cc Maxim Levitsky <[email protected]>Cc Jarod Wilson <[email protected]>Signed-off-by Mauro Carvalho Chehab <[email protected]>
Good catch. /me kicks self for missing that one.
Acked-by Jarod Wilson <[email protected]>
Signature · 2 lines
Jarod Wilson [email protected]