Bug: Gamepad not mapped on closing content

Found a minor bug in RetroArch mapping gamepads: I’m using a PS3 Controller connected per OTG cable to my Nexus 5. Loading a game, everything works fine, remap files get loaded correctly and so on. Hitting ‘Close Content’ results in my gamepad being unmapped, and navigation in menus is only possible per touchscreen. Loading a game afterwards, everything works again. I’m suspecting it is due to the input driver for Android not correctly resetting? Windows RetroArch is working as expected. I have the latest nightly. But the bug is older - found it a few days ago.

I have created a log file for nightly 2016-03-24. This time I open RetroArch, load F-Zero, and hit close content. RetroArch claims it is mapping the gamepad, but input won’t register. Finally, I close the app. I have also tried another gamepad (some cheap, obscure DS3 remake), same problem.

Will create issue on github.

https://gist.github.com/nutbro/fff5505212532095c4c5002c635aff6c