Fix exception if number starts with an unexpected character