summaryrefslogtreecommitdiff
path: root/export-image
diff options
context:
space:
mode:
Diffstat (limited to 'export-image')
-rwxr-xr-xexport-image/prerun.sh2
1 files changed, 1 insertions, 1 deletions
diff --git a/export-image/prerun.sh b/export-image/prerun.sh
index 2d8e1bb..267bbe0 100755
--- a/export-image/prerun.sh
+++ b/export-image/prerun.sh
@@ -35,7 +35,7 @@ if [ "${NO_PRERUN_QCOW2}" = "0" ]; then
echo "Creating loop device..."
cnt=0
- until LOOP_DEV="$(losetup --show --find --partscan "$IMG_FILE")"; do
+ until ensure_next_loopdev && LOOP_DEV="$(losetup --show --find --partscan "$IMG_FILE")"; do
if [ $cnt -lt 5 ]; then
cnt=$((cnt + 1))
echo "Error in losetup. Retrying..."