diff --git a/base/applications/regedit/framewnd.c b/base/applications/regedit/framewnd.c index 6f382a072cd..caa73edace8 100644 --- a/base/applications/regedit/framewnd.c +++ b/base/applications/regedit/framewnd.c @@ -1153,8 +1153,12 @@ static BOOL _CmdWndProc(HWND hWnd, UINT message, WPARAM wParam, LPARAM lParam) valueName = GetValueName(g_pChildWnd->hListWnd, -1); if (keyPath) { - if (RegOpenKeyExW(hKeyRoot, keyPath, 0, regsam, &hKey) != ERROR_SUCCESS) + LSTATUS nRes = RegOpenKeyExW(hKeyRoot, keyPath, 0, regsam, &hKey); + if (nRes != ERROR_SUCCESS) + { hKey = 0; + ErrorMessageBox(hWnd,NULL,nRes); + } } switch (LOWORD(wParam))