mirror of
https://github.com/reactos/reactos.git
synced 2024-07-06 20:55:16 +00:00
[USETUP]
Fix installation directories set into unattend.inf, they were ignored and installed always into \ReactOS. svn path=/trunk/; revision=55884
This commit is contained in:
parent
aaa881ed5a
commit
806732f98e
|
@ -506,10 +506,10 @@ CheckUnattendedSetup(VOID)
|
||||||
|
|
||||||
UnattendDestinationPartitionNumber = IntValue;
|
UnattendDestinationPartitionNumber = IntValue;
|
||||||
|
|
||||||
/* Search for 'DestinationPartitionNumber' in the 'Unattend' section */
|
/* Search for 'InstallationDirectory' in the 'Unattend' section */
|
||||||
if (!SetupFindFirstLineW(UnattendInf, L"Unattend", L"DestinationPartitionNumber", &Context))
|
if (!SetupFindFirstLineW(UnattendInf, L"Unattend", L"InstallationDirectory", &Context))
|
||||||
{
|
{
|
||||||
DPRINT("SetupFindFirstLine() failed for key 'DestinationPartitionNumber'\n");
|
DPRINT("SetupFindFirstLine() failed for key 'InstallationDirectory'\n");
|
||||||
SetupCloseInfFile(UnattendInf);
|
SetupCloseInfFile(UnattendInf);
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
@ -2594,8 +2594,6 @@ InstallDirectoryPage(PINPUT_RECORD Ir)
|
||||||
PDISKENTRY DiskEntry;
|
PDISKENTRY DiskEntry;
|
||||||
PPARTENTRY PartEntry;
|
PPARTENTRY PartEntry;
|
||||||
WCHAR InstallDir[51];
|
WCHAR InstallDir[51];
|
||||||
PWCHAR DefaultPath;
|
|
||||||
INFCONTEXT Context;
|
|
||||||
ULONG Length;
|
ULONG Length;
|
||||||
|
|
||||||
if (PartitionList == NULL ||
|
if (PartitionList == NULL ||
|
||||||
|
@ -2609,22 +2607,10 @@ InstallDirectoryPage(PINPUT_RECORD Ir)
|
||||||
DiskEntry = PartitionList->CurrentDisk;
|
DiskEntry = PartitionList->CurrentDisk;
|
||||||
PartEntry = PartitionList->CurrentPartition;
|
PartEntry = PartitionList->CurrentPartition;
|
||||||
|
|
||||||
/* Search for 'DefaultPath' in the 'SetupData' section */
|
if (IsUnattendedSetup)
|
||||||
if (!SetupFindFirstLineW(SetupInf, L"SetupData", L"DefaultPath", &Context))
|
wcscpy(InstallDir, UnattendInstallationDirectory);
|
||||||
{
|
|
||||||
MUIDisplayError(ERROR_FIND_SETUPDATA, Ir, POPUP_WAIT_ENTER);
|
|
||||||
return QUIT_PAGE;
|
|
||||||
}
|
|
||||||
|
|
||||||
/* Read the 'DefaultPath' data */
|
|
||||||
if (INF_GetData(&Context, NULL, &DefaultPath))
|
|
||||||
{
|
|
||||||
wcscpy(InstallDir, DefaultPath);
|
|
||||||
}
|
|
||||||
else
|
else
|
||||||
{
|
|
||||||
wcscpy(InstallDir, L"\\ReactOS");
|
wcscpy(InstallDir, L"\\ReactOS");
|
||||||
}
|
|
||||||
|
|
||||||
Length = wcslen(InstallDir);
|
Length = wcslen(InstallDir);
|
||||||
CONSOLE_SetInputTextXY(8, 11, 51, InstallDir);
|
CONSOLE_SetInputTextXY(8, 11, 51, InstallDir);
|
||||||
|
|
Loading…
Reference in a new issue