mirror of
https://github.com/ApfelTeeSaft/reactos.git
synced 2026-09-03 04:13:31 +00:00
LiveCD change: don't directly name the shell executable in SYSTEM\Setup key, but run setup.exe, which then loads syssetup.dll, which then runs the selected shell.
This is the first step to do custom operations when running the livecd. svn path=/trunk/; revision=23016
This commit is contained in:
@@ -85,6 +85,33 @@ RunNewSetup (HINSTANCE hInstance)
|
||||
FreeLibrary (hDll);
|
||||
}
|
||||
|
||||
static VOID
|
||||
RunLiveCD (HINSTANCE hInstance)
|
||||
{
|
||||
HMODULE hDll;
|
||||
PINSTALL_REACTOS InstallLiveCD;
|
||||
|
||||
hDll = LoadLibrary (TEXT("syssetup"));
|
||||
if (hDll == NULL)
|
||||
{
|
||||
DPRINT("Failed to load 'syssetup'!\n");
|
||||
return;
|
||||
}
|
||||
|
||||
DPRINT("Loaded 'syssetup'!\n");
|
||||
InstallLiveCD = (PINSTALL_REACTOS)GetProcAddress (hDll, "InstallLiveCD");
|
||||
|
||||
if (InstallLiveCD == NULL)
|
||||
{
|
||||
DPRINT("Failed to get address for 'InstallReactOS()'!\n");
|
||||
FreeLibrary (hDll);
|
||||
return;
|
||||
}
|
||||
|
||||
InstallLiveCD (hInstance);
|
||||
|
||||
FreeLibrary (hDll);
|
||||
}
|
||||
|
||||
int STDCALL
|
||||
WinMain (HINSTANCE hInstance,
|
||||
@@ -107,6 +134,10 @@ WinMain (HINSTANCE hInstance,
|
||||
{
|
||||
RunNewSetup (hInstance);
|
||||
}
|
||||
else if (!lstrcmpi (p, TEXT("-mini")))
|
||||
{
|
||||
RunLiveCD (hInstance);
|
||||
}
|
||||
|
||||
#if 0
|
||||
/* Add new setup types here */
|
||||
|
||||
Reference in New Issue
Block a user