commit | 3172bc4a19e0166137be7ff265158e7dcdc497c4 | [log] [tgz] |
---|---|---|
author | Kirill Makurin <maiddaisuki@outlook.com> | Sat Sep 06 18:46:08 2025 +0900 |
committer | LIU Hao <lh_mouse@126.com> | Sun Sep 07 22:53:44 2025 +0800 |
tree | 534260b8a3db59d532fae8f43f990ba09e2612df | |
parent | 73c17f04b51fa360413b90adab5401a5c947e8df [diff] |
crt: avoid sign-extension of argument to isleadbyte in mbrtowc Passing an argument of type `char` to isleadbyte may result in sign-extension of its argument. crtdll.dll's isleadbyte does not handle sign-extended input properly, which result in incorrect behavior of mbrlen and mbrtowc functions. Add cast to `unsigned char` to avoid this. Signed-off-by: Kirill Makurin <maiddaisuki@outlook.com> Signed-off-by: LIU Hao <lh_mouse@126.com>