From e78639b46f9f5be01cf4e30792199da6a531bf92 Mon Sep 17 00:00:00 2001 From: Kairui Song Date: Wed, 11 Mar 2020 01:32:32 +0800 Subject: [PATCH] Use read_strip_comments to filter the installed kdump.conf This help remove redundant spaces and tailing comment in installed kdump.conf, currently installed kdump.conf always contain extra empty lines. Signed-off-by: Kairui Song Acked-by: Lianbo Jiang --- dracut-module-setup.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/dracut-module-setup.sh b/dracut-module-setup.sh index a18d765..b4cfe0e 100755 --- a/dracut-module-setup.sh +++ b/dracut-module-setup.sh @@ -487,7 +487,7 @@ adjust_bind_mount_path() #install kdump.conf and what user specifies in kdump.conf kdump_install_conf() { local _opt _val _pdev - sed -ne '/^#/!p' /etc/kdump.conf > ${initdir}/tmp/$$-kdump.conf + (read_strip_comments /etc/kdump.conf) > ${initdir}/tmp/$$-kdump.conf while read _opt _val; do