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

fix: Undeclared variable in ConvertDisk (#1037)

parent 8d021136
Loading
Loading
Loading
Loading
+4 −2
Original line number Diff line number Diff line
@@ -255,12 +255,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)