Correctly free ipnut handle upon error

Coverity 28847 Resource leak
linux2hid translation table needs to be wide enough

The codes from the kernel are 8-bit.
Coverity 28846 Out-of-bounds read
Avoid a write buffer overflow

Cap the array properly.
Coverity 28844 Out-of-bounds write
Coverity 28845 Out-of-bounds write
Error check setsockopt()

Coverity 28841 Unchecked return value from library
Coverity 28840 Unchecked return value from library
Tear down control connection if we did not manage to open interrupt one

Coverity 28843 Improper use of negative value
Increase version