ToadKing / wii-u-gc-adapter

Tool for using the Wii U GameCube Adapter on Linux
MIT License
241 stars 44 forks source link

Fixed write if less than all pending bytes were written in one operation #25

Closed Emill closed 8 years ago

Emill commented 8 years ago

When I run the program, I get a lot of "Warning: writing input events failed" when I touch any button or stick on my controller but no events are received by my games.

I figured out the write code to uinput is not correct. This patch makes sure all data is written even if all data couldn't be written in a single write command.

This should fix #23.

ToadKing commented 8 years ago

looks okay to merge, i'll probably want to go and replace some the fprintf error calls to use perror in the future, but that's for another PR