HomeFreeBSD

stand/lua: Fix module_path handling with multiple kernels

Description

stand/lua: Fix module_path handling with multiple kernels

Once we've successfully loaded a kernel, we add its directory to
module_path. If we switch kernels with the kernel selector, we again prepend
the kernel directory to the current module_path and end up with multiple
kernel paths, potentially with mismatched kernel/modules, added to
module_path.

Fix it by caching module_path at load() time and using the cached version
whenever we load a new kernel.

Details

Provenance
kevansAuthored on
Parents
rS329496: stand/lua: Fix verbiage and some typos
Branches
Unknown
Tags
Unknown