https://bugs.winehq.org/show_bug.cgi?id=54058
Bug ID: 54058 Summary: user32:input - test_ToAscii() fails in the Hindi UTF-8 locale Product: Wine Version: unspecified Hardware: x86-64 OS: Windows Status: NEW Severity: normal Priority: P2 Component: user32 Assignee: wine-bugs@winehq.org Reporter: fgouget@codeweavers.com
Created attachment 73613 --> https://bugs.winehq.org/attachment.cgi?id=73613 user32/tests: Skip a ToAscii() test in UTF-8 code pages.
user32:input - test_ToAscii() fails in the Hindi UTF-8 locale:
input.c:3133: Test failed: ToAscii for character 'A' didn't return 1 (was 0)
See https://test.winehq.org/data/patterns.html#user32:input
Note that this did not happen before 2022-11-21 because some unknown Windows quirk caused the UserDefaultLCID and ThreadLocale to be reset to English before the test was started.
In any case it seems ToAscii() does not depend just on the keyboard layout but also on the current code page which makes sense. So then maybe we should limit the test to non-UTF-8 code pages as in the attached patch?
https://bugs.winehq.org/show_bug.cgi?id=54058
--- Comment #1 from François Gouget fgouget@codeweavers.com --- Actually the test works in the en-AE UTF-8 locale. So maybe it's not just the code page that matters but it's combination with the keyboard, or the user locale.
But then maybe we don't care about the corner cases and just making sure the test succeeds in a few well known locales is all that matters?
https://bugs.winehq.org/show_bug.cgi?id=54058
François Gouget fgouget@codeweavers.com changed:
What |Removed |Added ---------------------------------------------------------------------------- Keywords| |source, testcase
https://bugs.winehq.org/show_bug.cgi?id=54058
François Gouget fgouget@codeweavers.com changed:
What |Removed |Added ---------------------------------------------------------------------------- Assignee|wine-bugs@winehq.org |fgouget@codeweavers.com
--- Comment #2 from François Gouget fgouget@codeweavers.com --- I sent a fix: https://gitlab.winehq.org/wine/wine/-/merge_requests/2195
https://bugs.winehq.org/show_bug.cgi?id=54058
François Gouget fgouget@codeweavers.com changed:
What |Removed |Added ---------------------------------------------------------------------------- Status|NEW |RESOLVED Fixed by SHA1| |df811f91cc2821dd14fa1b72d4e | |474fb4720624e Resolution|--- |FIXED
--- Comment #3 from François Gouget fgouget@codeweavers.com --- This is fixed:
commit df811f91cc2821dd14fa1b72d4e474fb4720624e Author: François Gouget fgouget@codeweavers.com AuthorDate: Wed Feb 15 04:18:59 2023 +0100
user32/tests: Fix the ToAscii(A) test on Hindi + UTF-8.
ToAscii() can only return two bytes and thus cannot return three-byte UTF-8 characters.
Wine-Bug: https://bugs.winehq.org//show_bug.cgi?id=54058
https://bugs.winehq.org/show_bug.cgi?id=54058
Alexandre Julliard julliard@winehq.org changed:
What |Removed |Added ---------------------------------------------------------------------------- Status|RESOLVED |CLOSED
--- Comment #4 from Alexandre Julliard julliard@winehq.org --- Closing bugs fixed in 8.4.