Skip to content

Commit b335db9

Browse files
committed
registry.... wndproc
1 parent 21271a7 commit b335db9

File tree

2 files changed

+2
-8
lines changed

2 files changed

+2
-8
lines changed

progmgr/registry.c

+1-4
Original file line numberDiff line numberDiff line change
@@ -336,11 +336,8 @@ DWORD LoadConfig(_In_ BOOL bSettings, _In_ BOOL bPos, _In_ BOOL bGroups)
336336
}
337337

338338
// retrieve the group
339-
// TODO: add error_checking, ERROR_FILE_NOT_FOUND
340-
// stuff like that, please
341-
// error checking makes reliability....
342339
error = RegGetValue(hKeyProgramGroups, NULL, szGroupValName, RRF_RT_REG_BINARY, NULL, pGroup, &cbGroup);
343-
/*error = RegQueryValueEx(hKeyProgramGroups, szGroupValName, NULL, NULL, pGroup, &cbGroup);*/
340+
344341
if (error == ERROR_FILE_NOT_FOUND)
345342
{
346343
OutputDebugString(TEXT("REGISTRY.C: Group not found!\n"));

progmgr/wndproc.c

+1-4
Original file line numberDiff line numberDiff line change
@@ -68,6 +68,7 @@ LRESULT CALLBACK WndProc(HWND hWnd, UINT message, WPARAM wParam, LPARAM lParam)
6868
return DefFrameProc(hWnd, hWndMDIClient, message, wParam, lParam);
6969

7070
case WM_CLOSE:
71+
case WM_ENDSESSION:
7172
if (bSaveSettings)
7273
SaveConfig(TRUE, TRUE, TRUE, TRUE);
7374

@@ -77,10 +78,6 @@ LRESULT CALLBACK WndProc(HWND hWnd, UINT message, WPARAM wParam, LPARAM lParam)
7778
PostQuitMessage(0);
7879
break;
7980

80-
case WM_ENDSESSION:
81-
PostQuitMessage(0);
82-
break;
83-
8481
default:
8582
return DefFrameProc(hWnd, hWndMDIClient, message, wParam, lParam);
8683
}

0 commit comments

Comments
 (0)