HomeFreeBSD

loader: possible NULL pointer dereference in efipart.c

Description

loader: possible NULL pointer dereference in efipart.c

Fix bugs found by Coverity in efipart.c.

The Issue is that efi_devpath_last_node() can return NULL pointer, and
therefore we should check for it. In real life we really do not
expect to see it to happen, so we will just error out from the test.

CID: 1371004
Reported by: Coverity
Reviewed by: allanjude
Approved by: allanjude (mentor)
Differential Revision: https://reviews.freebsd.org/D9490

Details

Provenance
tsoomeAuthored on
Reviewer
allanjude
Differential Revision
D9490: loader: possible NULL pointer dereference in efipart.c
Parents
rS313441: MFC r312777, r312780:
Branches
Unknown
Tags
Unknown