[EXPLORER][EXPLORER_NEW]

[TASKMGR]
Set a proper shutdown level (with SetProcessShutdownParameters) so that explorer and taskmgr are terminated the very last when one shutdowns ReactOS.
See Windows Internals 4th page 286 (section "Shutdown") which gives the values (that I've cross-checked on Windows 2k3 too).

svn path=/trunk/; revision=63601
This commit is contained in:
Hermès Bélusca-Maïto 2014-06-15 20:02:26 +00:00
parent 8c1cde9a6a
commit 09fe96f361
2 changed files with 12 additions and 0 deletions

View file

@ -172,6 +172,12 @@ int APIENTRY wWinMain(HINSTANCE hInstance,
return -1;
}
/*
* Set our shutdown parameters: we want to shutdown the very last,
* without displaying any end task dialog if needed.
*/
SetProcessShutdownParameters(1, SHUTDOWN_NORETRY);
DialogBoxW(hInst, (LPCWSTR)IDD_TASKMGR_DIALOG, NULL, TaskManagerWndProc);
/* Save our settings to the registry */

View file

@ -1203,6 +1203,12 @@ int WINAPI _tWinMain(HINSTANCE hInstance, HINSTANCE hPrevInstance, LPTSTR lpCmdL
"ROS Explorer - command line options", MB_OK);
}
/*
* Set our shutdown parameters: we want to shutdown the very last,
* but before any TaskMgr instance (which has a shutdown level of 1).
*/
SetProcessShutdownParameters(2, 0);
Thread* pSSOThread = NULL;
if (startup_desktop) {