Fix possible memory leaks in hidpad_ps3_connect, hidpad_ps4_connect, and  hidpad_wii_connect