block.qubes: pass arguments correctly to other scripts

This commit is contained in:
Rafal Wojtczuk 2011-03-23 09:31:44 +01:00
parent 105486135b
commit 4e78284e4f

View File

@ -28,7 +28,7 @@ hexnumber()
process()
{
if ! [ "x""$1" = "xfile" ] ; then
exec /etc/xen/scripts/block "$@"
exec /etc/xen/scripts/block $ORIG_ARGS
fi
while true ; do
dev=$(losetup -f --show $2)
@ -48,6 +48,8 @@ XENBUS_PATH="${XENBUS_PATH:?}"
if ! [ "$1" = "add" ] || ! [ -f /var/run/qubes/fast_block_attach ] ; then
exec /etc/xen/scripts/block "$@"
fi
ORIG_ARGS="$@"
vars=$(xenstore-read "$XENBUS_PATH/type" "$XENBUS_PATH/params")
process $vars