From: Silvio Rhatto Date: Mon, 19 Oct 2020 17:45:37 +0000 (-0300) Subject: Fix: syntax check at rsync_to and rsync_from X-Git-Tag: 0.1.0~76 X-Git-Url: https://gitweb.fluxo.info/?a=commitdiff_plain;h=303112146f242da44ccb9f7c2afe5c0f28fa0110;p=kvmx.git Fix: syntax check at rsync_to and rsync_from --- diff --git a/kvmx b/kvmx index 3759502..b4e7d18 100755 --- a/kvmx +++ b/kvmx @@ -1208,6 +1208,11 @@ function kvmx_rsync_to { ORIG="$1" DEST="$2" + if [ -z "$ORIG" ]; then + echo "usage $BASENAME rsync_to $GUEST [dest]" + exit 1 + fi + if [ -z "$DEST" ]; then # Error #exit 1 @@ -1240,6 +1245,11 @@ function kvmx_rsync_from { ORIG="$1" DEST="$2" + if [ -z "$ORIG" ]; then + echo "usage $BASENAME rsync_from $GUEST [dest]" + exit 1 + fi + if [ -z "$DEST" ]; then # Error #exit 1