Skip to content

Commit

Permalink
fix(dracut-init.sh): module_check method ignores forced option
Browse files Browse the repository at this point in the history
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.
  • Loading branch information
aafeijoo-suse authored and LaszloGombos committed Jul 24, 2023
1 parent c4e6eaf commit 6c9f403
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion dracut-init.sh
Original file line number Diff line number Diff line change
Expand Up @@ -764,7 +764,7 @@ module_check() {
local _forced=0
local _hostonly=$hostonly
[[ -z $_moddir ]] && _moddir=$(dracut_module_path "$1")
[ $# -eq 2 ] && _forced=$2
[ $# -ge 2 ] && _forced=$2
[[ -d $_moddir ]] || return 1
if [[ ! -f $_moddir/module-setup.sh ]]; then
# if we do not have a check script, we are unconditionally included
Expand Down

0 comments on commit 6c9f403

Please sign in to comment.