Skip to content

Commit

Permalink
fix(base): do not quote $initargs for switch_root
Browse files Browse the repository at this point in the history
We want word splitting to occur so that the arguments are passed
separately, and we don't end up passing an empty string if no arguments
are specified.

Bug: https://bugs.gentoo.org/803548
Fixes: 2fabaaa
  • Loading branch information
floppym authored and johannbg committed Aug 6, 2021
1 parent cbd8559 commit f649cd1
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion modules.d/99base/init.sh
Original file line number Diff line number Diff line change
Expand Up @@ -387,7 +387,8 @@ if [ -f /etc/capsdrop ]; then
}
else
unset RD_DEBUG
exec "$SWITCH_ROOT" "$NEWROOT" "$INIT" "$initargs" || {
# shellcheck disable=SC2086
exec "$SWITCH_ROOT" "$NEWROOT" "$INIT" $initargs || {
warn "Something went very badly wrong in the initramfs. Please "
warn "file a bug against dracut."
emergency_shell
Expand Down

0 comments on commit f649cd1

Please sign in to comment.