improve utf8_to_unicode function to support multi languages

Change-Id: I8e0b3d225ef1d4a5f6d89a29b1cff5c934708ca2