Skip to content

Commit

Permalink
Input: iforce - do not return ENOMEM upon successful allocation
Browse files Browse the repository at this point in the history
Signed-off-by: Alexey Dobriyan <adobriyan@gmail.com>
Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
  • Loading branch information
Alexey Dobriyan authored and Dmitry Torokhov committed Jan 30, 2006
1 parent a3f3f31 commit 5ae08f8
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion drivers/input/joystick/iforce/iforce-main.c
Original file line number Diff line number Diff line change
Expand Up @@ -345,7 +345,7 @@ int iforce_init_device(struct iforce *iforce)
int i;

input_dev = input_allocate_device();
if (input_dev)
if (!input_dev)
return -ENOMEM;

init_waitqueue_head(&iforce->wait);
Expand Down

0 comments on commit 5ae08f8

Please sign in to comment.