Page MenuHomeFreeBSD

libbe: bail out early if the zfs kmod isn't loaded
ClosedPublic

Authored by kevans on Aug 13 2022, 12:22 AM.
Tags
None
Referenced Files
Unknown Object (File)
Tue, Apr 21, 5:30 PM
Unknown Object (File)
Tue, Apr 21, 5:41 AM
Unknown Object (File)
Sun, Apr 19, 12:07 AM
Unknown Object (File)
Sat, Apr 18, 4:58 AM
Unknown Object (File)
Fri, Apr 17, 8:06 PM
Unknown Object (File)
Fri, Apr 17, 7:52 PM
Unknown Object (File)
Fri, Apr 17, 5:13 AM
Unknown Object (File)
Thu, Apr 16, 1:50 PM
Subscribers

Details

Summary

As noted in the comment, we already know the rest of libbe_init() will
fail because there's no pool imported. Avoid the side effect by
checking beforehand and bailing out early.

With this, freebsd-update(8) should no longer trigger a load of the zfs
kmod just because it runs bectl check.

Diff Detail

Repository
rG FreeBSD src repository
Lint
Lint Not Applicable
Unit
Tests Not Applicable