Skip to content

Commit

Permalink
[media] rc-core: Initialize return value to zero
Browse files Browse the repository at this point in the history
At ir_setkeycode, if INPUT_KEYMAP_BY_INDEX is used, the routine may return
an invalid value if not error.

Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
  • Loading branch information
Mauro Carvalho Chehab committed Dec 29, 2010
1 parent b7c7a4b commit dea8a39
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion drivers/media/rc/rc-main.c
Original file line number Diff line number Diff line change
Expand Up @@ -325,7 +325,7 @@ static int ir_setkeycode(struct input_dev *idev,
struct rc_map *rc_map = &rdev->rc_map;
unsigned int index;
unsigned int scancode;
int retval;
int retval = 0;
unsigned long flags;

spin_lock_irqsave(&rc_map->lock, flags);
Expand Down

0 comments on commit dea8a39

Please sign in to comment.