Fixed possible problems in InputCommon