Skip to content

Commit 6c9f403

Browse files
aafeijoo-suseLaszloGombos
authored andcommitted
fix(dracut-init.sh): module_check method ignores forced option
When the `module_check` method is called passing 3 arguments (all calls right now), the `forced` option is ignored, so the `hostonly` variable is never unset before the module's `check` method is called.
1 parent c4e6eaf commit 6c9f403

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

dracut-init.sh

+1-1
Original file line numberDiff line numberDiff line change
@@ -764,7 +764,7 @@ module_check() {
764764
local _forced=0
765765
local _hostonly=$hostonly
766766
[[ -z $_moddir ]] && _moddir=$(dracut_module_path "$1")
767-
[ $# -eq 2 ] && _forced=$2
767+
[ $# -ge 2 ] && _forced=$2
768768
[[ -d $_moddir ]] || return 1
769769
if [[ ! -f $_moddir/module-setup.sh ]]; then
770770
# if we do not have a check script, we are unconditionally included

0 commit comments

Comments
 (0)