]> git.ipfire.org Git - thirdparty/dracut-ng.git/commit
fix(dracut): source dracut-functions.sh before calling dwarning
authorBenjamin Drung <benjamin.drung@canonical.com>
Mon, 5 Jan 2026 23:32:20 +0000 (00:32 +0100)
committerNeal Gompa (ニール・ゴンパ) <ngompa13@gmail.com>
Tue, 6 Jan 2026 11:31:50 +0000 (06:31 -0500)
commit8552a0f443ffeacd6529f0c86896f64d1b646fbe
tree240c77c79519e6053d396941d777a0ebfc5364e9
parentee0c813874fcbc55f52d47aa856344821fd833b4
fix(dracut): source dracut-functions.sh before calling dwarning

`dracut-functions.sh` sources `dracut-logger.sh` which defines the
`dwarning` function. `dracut.sh` might call `dwarning` before
`dracut-functions.sh` is sourced.

`dracut-functions.sh` calls `find_binary` and `dlog_init` when sourced.
`find_binary` needs `dracutsysrootdir` set and `dlog_init` needs
`stdloglvl`, `sysloglvl`, `kmsgloglvl`, `maxloglvl`, `fileloglvl`,
`logfile`. Move sourcing `dracut-functions.sh` as early as possible, but
after setting those variables.

Follow-up for 8d9887b
Fixes: https://bugs.debian.org/1124479
dracut.sh