Unverified Commit 41fc0a6a authored by Kroese's avatar Kroese Committed by GitHub
Browse files

fix: Undeclared variable in ConvertDisk (#1147)

parent 7753e4ac
Loading
Loading
Loading
Loading
+4 −2
Original line number Diff line number Diff line
@@ -269,12 +269,14 @@ convertDisk() {
  local TMP_FILE="$DISK_BASE.tmp"
  rm -f "$TMP_FILE"

  local DIR
  DIR=$(dirname "$TMP_FILE")

  if [[ "$ALLOCATE" != [Nn]* ]]; then

    local DIR CUR_SIZE SPACE GB
    local CUR_SIZE SPACE GB

    # Check free diskspace
    DIR=$(dirname "$TMP_FILE")
    CUR_SIZE=$(getSize "$SOURCE_FILE")
    SPACE=$(df --output=avail -B 1 "$DIR" | tail -n 1)