modify Utf8 and Utf16 decode_code_point to let them more safe