Skip to content

Commit

Permalink
OcMainLib: Fix bootstrap path left incorrect in the previous commit
Browse files Browse the repository at this point in the history
  • Loading branch information
vit9696 committed Jan 31, 2021
1 parent 69ff426 commit 8c0ca12
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 6 deletions.
2 changes: 0 additions & 2 deletions Include/Acidanthera/Library/OcMainLib.h
Original file line number Diff line number Diff line change
Expand Up @@ -50,8 +50,6 @@

#define OPEN_CORE_DRIVER_PATH L"OpenCore.efi"

#define OPEN_CORE_BOOTSTRAP_PATH L"Bootstrap\\Bootstrap.efi"

#define OPEN_CORE_CONFIG_PATH L"config.plist"

#define OPEN_CORE_LOG_PREFIX_PATH L"opencore"
Expand Down
8 changes: 4 additions & 4 deletions Library/OcMainLib/OpenCoreMisc.c
Original file line number Diff line number Diff line change
Expand Up @@ -623,12 +623,12 @@ RegisterLauncherOption (
UINTN BootstrapSize;

if (AsciiStrCmp (LauncherPath, "Default") == 0) {
BootstrapSize = StrSize (RootPath) + StrSize (OPEN_CORE_BOOTSTRAP_PATH);
BootstrapSize = StrSize (RootPath) + StrSize (OPEN_CORE_DRIVER_PATH);
BootstrapPath = AllocatePool (BootstrapSize);
if (BootstrapPath == NULL) {
return 0;
}
UnicodeSPrint (BootstrapPath, BootstrapSize, L"%s\\%s", RootPath, OPEN_CORE_BOOTSTRAP_PATH);
UnicodeSPrint (BootstrapPath, BootstrapSize, L"%s\\%s", RootPath, OPEN_CORE_DRIVER_PATH);
} else {
BootstrapPath = AsciiStrCopyToUnicode (LauncherPath, 0);
if (BootstrapPath == NULL) {
Expand All @@ -641,8 +641,8 @@ RegisterLauncherOption (
LoadHandle,
BootstrapPath,
ShortForm,
OPEN_CORE_BOOTSTRAP_PATH,
L_STR_LEN (OPEN_CORE_BOOTSTRAP_PATH)
BootstrapPath,
StrLen (BootstrapPath)
);
FreePool (BootstrapPath);

Expand Down

0 comments on commit 8c0ca12

Please sign in to comment.