missing boot environments cause bootadm list-menu to segfault
Somewhere in the process of upgrading my system the GRUB menu.lst was not updated. This left me with a menu file that references datasets which are no longer present and causes bootadm list-menu to segfault.
If you look at the code in the print_menu_nodes function you will see that it walks the list of boot environments looking for a match. if it is unable to find one the be_node variable is left set to NULL. This then leads to a NULL pointer dereference when the be_active_on_boot member is accessed.
Updated by Electric Monk over 5 years ago
- Status changed from New to Closed
- % Done changed from 0 to 100
commit 760a3dc429d80e72277b67bec8135d2d185efe9a Author: Toomas Soome <email@example.com> Date: 2017-06-10T16:16:47.000Z 8129 bootadm: add support for non-zfs boot entries in menu.lst 8226 missing boot environments cause bootadm list-menu to segfault Reviewed by: Yuri Pankov <firstname.lastname@example.org> Reviewed by: Hans Rosenfeld <email@example.com> Reviewed by: John Howard <Echosoft.LLC@gmail.com> Reviewed by: Andrew Stormont <firstname.lastname@example.org> Approved by: Richard Lowe <email@example.com>