korean is broken by utf8(). But, korean is not broken when latin1() is used. It seems to me that this is strange. I test this by below codes. printf("<< korean string test(utf8) : %s \n", String("한글").utf8().data()); printf("<< korean string test(latin1) : %s \n", String("한글").latin1().data()); Does anyone know why korean is broken ? If my test is something wrong, please let me know. Thank you.
Result of above test : korean string test(utf8) : íê¸ korean string test(latin1) : 한글
In order to use utf8, we should use fromUTF8() as below, printf("<< korean string test(utf8) : %s \n", (String::fromUTF8("한글")).utf8().data());