Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
dadigang
Ventoy
Commits
35c952d8
"docs/vscode:/vscode.git/clone" did not exist on "72b712a1eef4f3ba292b8712e2acf15519d61378"
Unverified
Commit
35c952d8
authored
May 19, 2023
by
A1ive
Committed by
GitHub
May 19, 2023
Browse files
Correct EFI chainloader image device path (#2397)
parent
82053680
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
5 additions
and
15 deletions
+5
-15
GRUB2/MOD_SRC/grub-2.04/grub-core/loader/efi/chainloader.c
GRUB2/MOD_SRC/grub-2.04/grub-core/loader/efi/chainloader.c
+5
-15
No files found.
GRUB2/MOD_SRC/grub-2.04/grub-core/loader/efi/chainloader.c
View file @
35c952d8
...
...
@@ -229,10 +229,7 @@ grub_cmd_chainloader (grub_command_t cmd __attribute__ ((unused)),
if
(
!
file
)
goto
fail
;
/* Get the root device's device path. */
dev
=
grub_device_open
(
0
);
if
(
!
dev
)
goto
fail
;
dev
=
file
->
device
;
if
(
dev
->
disk
)
dev_handle
=
grub_efidisk_get_device_handle
(
dev
->
disk
);
...
...
@@ -257,16 +254,13 @@ grub_cmd_chainloader (grub_command_t cmd __attribute__ ((unused)),
if
(
dev_handle
)
dp
=
grub_efi_get_device_path
(
dev_handle
);
if
(
!
dp
)
if
(
dp
!=
NULL
)
{
grub_error
(
GRUB_ERR_BAD_DEVICE
,
"not a valid root device"
);
goto
fail
;
file_path
=
make_file_path
(
dp
,
filename
);
if
(
!
file_path
)
goto
fail
;
}
file_path
=
make_file_path
(
dp
,
filename
);
if
(
!
file_path
)
goto
fail
;
//grub_printf ("file path: ");
//grub_efi_print_device_path (file_path);
...
...
@@ -390,16 +384,12 @@ grub_cmd_chainloader (grub_command_t cmd __attribute__ ((unused)),
}
grub_file_close
(
file
);
grub_device_close
(
dev
);
grub_loader_set
(
grub_chainloader_boot
,
grub_chainloader_unload
,
0
);
return
0
;
fail:
if
(
dev
)
grub_device_close
(
dev
);
if
(
file
)
grub_file_close
(
file
);
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment