installgrub efi_alloc_and_read() return value check is faulty
installgrub is assuming 0 is failure from reading EFI label, but it is not so, 0 is perfectly legal value while reading whole disk device such as c0t0d0p0. efi_read() used by efi_alloc_and_read() is using DKIOCINFO to get partition number, and p0 has no partition, so 0 is legal there. For example, prtvtoc(1M) is interpreting this return value correctly.
Updated by Electric Monk over 5 years ago
- Status changed from New to Closed
- % Done changed from 0 to 100
commit cc641e8dc4d38800076a2260f4d959bf86003257 Author: Toomas Soome <email@example.com> Date: 2016-01-26T22:36:59.000Z 6579 installgrub efi_alloc_and_read() return value check is faulty Reviewed by: Igor Kozhukhov <firstname.lastname@example.org> Reviewed by: Andrew Stormont <email@example.com> Reviewed by: Hans Rosenfeld <firstname.lastname@example.org> Approved by: Robert Mustacchi <email@example.com>