Fix bug #13515 with processing DBCS file names on MS-Windows.
commitc423803a222cf7c7ead9e743077401ed8ff3c136
authorEli Zaretskii <eliz@gnu.org>
Wed, 23 Jan 2013 16:11:04 +0000 (23 18:11 +0200)
committerEli Zaretskii <eliz@gnu.org>
Wed, 23 Jan 2013 16:11:04 +0000 (23 18:11 +0200)
tree162a1ef2725c914179d8bc2ee2a84269f96d9a64
parenta2cbf03160f75a9adb84143150c28a36daf1bf71
Fix bug #13515 with processing DBCS file names on MS-Windows.

 src/w32.c (max_filename_mbslen): New function.
 (normalize_filename, readdir): Use it to detect locales where ANSI
 encoding of file names uses a double-byte character set (DBCS).
 If a DBCS encoding is used, advance by characters using
 CharNextExA, instead of incrementing a 'char *' pointer.  Use
 _mbslwr instead of _strlwr.
src/ChangeLog
src/w32.c