From 0eff533e7cd0d777faa309a7b4d54677998abd1a Mon Sep 17 00:00:00 2001 From: Aleksey Bragin Date: Thu, 12 May 2005 19:46:14 +0000 Subject: [PATCH] Added MessageBoxes in case of registry funcs errors svn path=/trunk/; revision=15245 --- reactos/lib/cpl/intl/locale.c | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/reactos/lib/cpl/intl/locale.c b/reactos/lib/cpl/intl/locale.c index acb230afaf1..25080e55e1e 100644 --- a/reactos/lib/cpl/intl/locale.c +++ b/reactos/lib/cpl/intl/locale.c @@ -102,7 +102,7 @@ void SetNewLocale(LCID lcid) if (ret != ERROR_SUCCESS) { // some serious error - //TODO: Tell user about it + MessageBoxW(NULL, L"Problem opening HKCU\\Control Panel\\International key", L"Big Problem", MB_OK); return; } @@ -116,7 +116,10 @@ void SetNewLocale(LCID lcid) ret = RegOpenKeyW(HKEY_LOCAL_MACHINE, L"SYSTEM\\CurrentControlSet\\Control\\NLS\\Language", &langKey); if (ret != ERROR_SUCCESS) + { + MessageBoxW(NULL, L"Problem opening HKLM\\SYSTEM\\CurrentControlSet\\Control\\NLS\\Language key", L"Big Problem", MB_OK); return; + } RegSetValueExW(langKey, L"Default", 0, REG_SZ, (BYTE *)value, valuesize ); RegSetValueExW(langKey, L"InstallLanguage", 0, REG_SZ, (BYTE *)value, valuesize );