[PATCH] vbscript/tests: Fix first-day-of-week test on mixed locales

Alex Henrie alexhenrie24 at gmail.com
Sun Dec 31 20:20:53 CST 2017


Signed-off-by: Alex Henrie <alexhenrie24 at gmail.com>
---
One of the test VMs uses the German language (first day Monday) but
Inuktitut dates (first day Sunday). When determining the first day of
the week, Inuktitut needs to take precedence, which it does when
LOCALE_USER_DEFAULT is used.

 dlls/vbscript/tests/run.c | 3 +--
 1 file changed, 1 insertion(+), 2 deletions(-)

diff --git a/dlls/vbscript/tests/run.c b/dlls/vbscript/tests/run.c
index 7c97db2a9b..ee811c6e5b 100644
--- a/dlls/vbscript/tests/run.c
+++ b/dlls/vbscript/tests/run.c
@@ -219,8 +219,7 @@ static void detect_locale(void)
                   PRIMARYLANGID(GetUserDefaultUILanguage()) == LANG_ENGLISH &&
                   PRIMARYLANGID(GetUserDefaultLangID()) == LANG_ENGLISH);
 
-    GetLocaleInfoA(pGetThreadUILanguage ? pGetThreadUILanguage() : GetUserDefaultUILanguage(),
-                   LOCALE_IFIRSTDAYOFWEEK | LOCALE_RETURN_NUMBER,
+    GetLocaleInfoA(LOCALE_USER_DEFAULT, LOCALE_IFIRSTDAYOFWEEK | LOCALE_RETURN_NUMBER,
                    (void*)&first_day_of_week, sizeof(first_day_of_week));
     first_day_of_week = 1 + (first_day_of_week + 1) % 7;
 }
-- 
2.15.1




More information about the wine-devel mailing list