HomeFreeBSD

loader: mod_loadkld() error: we previously assumed 'last_file' could be null

Description

loader: mod_loadkld() error: we previously assumed 'last_file' could be null

The last_file variable is used to reset the loadaddr variable back to original
value; however, it is possible the last_file is NULL, so we can not blindly
trust it. But then again, we can just save the original loadaddr and use
the saved value for recovery.

MFC after: 1w

Details

Provenance
tsoomeAuthored on
Parents
rS346001: loader: file_addmetadata() should check for memory allocation
Branches
Unknown
Tags
Unknown