R0.14b patch 2

April 4, 2022

String functions, f_puts and f_printf, cannot write the unicode characters not in BMP
to the file when FF_LFN_UNICODE == 2 (UTF-8).
This commit is contained in:
Christopher Williams
2022-05-09 17:37:44 -07:00
parent 99415e7a91
commit ab8c36b6e2
+1 -1
View File
@@ -6524,7 +6524,7 @@ static void putc_bfd (putbuff* pb, TCHAR c)
if ((BYTE)c < 0x80) break; /* Single byte? */
if (((BYTE)c & 0xE0) == 0xC0) pb->ct = 1; /* 2-byte sequence? */
if (((BYTE)c & 0xF0) == 0xE0) pb->ct = 2; /* 3-byte sequence? */
if (((BYTE)c & 0xF1) == 0xF0) pb->ct = 3; /* 4-byte sequence? */
if (((BYTE)c & 0xF8) == 0xF0) pb->ct = 3; /* 4-byte sequence? */
return;
} else { /* In the multi-byte sequence */
if (((BYTE)c & 0xC0) != 0x80) { /* Broken sequence? */