UTF-8 string delimiter

前端 未结 3 1289
悲&欢浪女
悲&欢浪女 2021-01-21 00:30

I am parsing a binary protocol which has UTF-8 strings interspersed among raw bytes. This particular protocol prefaces each UTF-8 string with a short (two bytes) indicating the

3条回答
  •  春和景丽
    2021-01-21 01:04

    UTF8 is not normally de-limited, you should be able to spot the multibyte characters in there by using the rules mentioned here: http://en.wikipedia.org/wiki/UTF-8#Description

提交回复
热议问题