Page MenuHomeFreeBSD

D13038.diff
No OneTemporary

D13038.diff

Index: head/sys/boot/efi/boot1/boot1.c
===================================================================
--- head/sys/boot/efi/boot1/boot1.c
+++ head/sys/boot/efi/boot1/boot1.c
@@ -460,22 +460,23 @@
imgpath = NULL;
if (status == EFI_SUCCESS) {
text = efi_devpath_name(img->FilePath);
- printf(" Load Path: %S\n", text);
- efi_setenv_freebsd_wcs("Boot1Path", text);
- efi_free_devpath_name(text);
-
- status = BS->HandleProtocol(img->DeviceHandle, &DevicePathGUID,
- (void **)&imgpath);
- if (status != EFI_SUCCESS) {
- DPRINTF("Failed to get image DevicePath (%lu)\n",
- EFI_ERROR_CODE(status));
- } else {
- text = efi_devpath_name(imgpath);
- printf(" Load Device: %S\n", text);
- efi_setenv_freebsd_wcs("Boot1Dev", text);
+ if (text != NULL) {
+ printf(" Load Path: %S\n", text);
+ efi_setenv_freebsd_wcs("Boot1Path", text);
efi_free_devpath_name(text);
- }
+ status = BS->HandleProtocol(img->DeviceHandle,
+ &DevicePathGUID, (void **)&imgpath);
+ if (status != EFI_SUCCESS) {
+ DPRINTF("Failed to get image DevicePath (%lu)\n",
+ EFI_ERROR_CODE(status));
+ } else {
+ text = efi_devpath_name(imgpath);
+ printf(" Load Device: %S\n", text);
+ efi_setenv_freebsd_wcs("Boot1Dev", text);
+ efi_free_devpath_name(text);
+ }
+ }
}
/* Get all the device handles */

File Metadata

Mime Type
text/plain
Expires
Mon, Aug 17, 9:05 PM (3 h, 42 m)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
36871824
Default Alt Text
D13038.diff (1 KB)

Event Timeline