mirror of
https://github.com/grub4dos/ntloader.git
synced 2025-05-09 12:11:09 +08:00
fix cmdline use-after-free bug
This commit is contained in:
parent
746aa67ca3
commit
4c89e48ea6
@ -301,7 +301,6 @@ EFI_STATUS EFIAPI efi_main (EFI_HANDLE image_handle,EFI_SYSTEM_TABLE *systab)
|
||||
|
||||
/* Process command line */
|
||||
process_cmdline (cmdline);
|
||||
efi_free (cmdline);
|
||||
DBG ("systab=%p image_handle=%p\n", systab, image_handle);
|
||||
if (nt_cmdline->initrd_path)
|
||||
efi_load_sfs_initrd (loaded->DeviceHandle, &initrd, &initrd_len);
|
||||
@ -315,6 +314,7 @@ EFI_STATUS EFIAPI efi_main (EFI_HANDLE image_handle,EFI_SYSTEM_TABLE *systab)
|
||||
|
||||
extract_initrd (initrd, initrd_len);
|
||||
|
||||
efi_free (cmdline);
|
||||
if (! bootmgr)
|
||||
die ("FATAL: no bootmgfw.efi\n");
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user