If the $1 parameter contains the blank, it may break the condition that whether the $1 parameter contains the "eth".
Quote the $1 to integrate it as one parameter.
Signed-off-by: Minfei Huang mhuang@redhat.com Acked-by: Baoquan He bhe@redhat.com Acked-by: Dave Young dyoung@redhat.com --- kdump-lib.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/kdump-lib.sh b/kdump-lib.sh index f24f08d..b886c5d 100755 --- a/kdump-lib.sh +++ b/kdump-lib.sh @@ -146,7 +146,7 @@ check_save_path_fs() kdump_setup_ifname() { local _ifname
- if [[ $1 =~ eth* ]]; then + if [[ "$1" =~ eth* ]]; then _ifname="kdump-$1" else _ifname="$1"