From 92593708917125ef0cf07ce08138393eaa7da54d Mon Sep 17 00:00:00 2001 From: Christian Ehrhardt Date: Mon, 13 Nov 2017 05:32:19 -0500 Subject: [PATCH] mk-pxelinux-ramfs: fix escaping kexec appends Currently multiple entries in a single append is broken by how the shell in busybox escapes them. No usual grouping with " or ' will work but calling them directly but without the --append in the variable will let busybox do the right thing. GitHub-ID: #16 Signed-off-by: Christian Ehrhardt Acked-by: Viktor Mihajlovski Signed-off-by: Michael Holzheu --- netboot/mk-pxelinux-ramfs | 12 +++++------- 1 file changed, 5 insertions(+), 7 deletions(-) diff --git a/netboot/mk-pxelinux-ramfs b/netboot/mk-pxelinux-ramfs index e7bd1de5..2cc65b74 100755 --- a/netboot/mk-pxelinux-ramfs +++ b/netboot/mk-pxelinux-ramfs @@ -386,15 +386,13 @@ else INITRD="" fi -if [ -n "$append" ] -then - APPEND="--append=$append" +if [ -z "$append" ]; then + echo "Kexec load: kexec -l /tmp/kernel $INITRD" + kexec -l /tmp/kernel $INITRD else - APPEND="" + echo "Kexec load: kexec -l /tmp/kernel $INITRD --append=\"$append\"" + kexec -l /tmp/kernel $INITRD --append="$append" fi - -echo "Kexec load: kexec -l /tmp/kernel $INITRD $APPEND" -kexec -l /tmp/kernel $INITRD $APPEND kexec -e EOF # -- end pxeboot script