Skip to content

Commit 8f9be2a

Browse files
fix: sanity check before shift
1 parent 6940d88 commit 8f9be2a

File tree

1 file changed

+5
-5
lines changed

1 file changed

+5
-5
lines changed

udroid/src/udroid.sh

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -320,14 +320,14 @@ login() {
320320
ELOG "ERROR: --bind requires a path"
321321
DIE "ERROR: --bind requires a path"
322322
}
323-
custom_fs_bindings+=("$2")
324-
shift 2
325323
if [[ -z $UDROID_MOUNT_SANITY_CHECK ]]; then
326-
[[ ! -d ${1%%:*} ]] && {
327-
LOG "WARNING: --bind path $1 not found"
328-
GWARN "WARNING: --bind path $1 not found"
324+
[[ ! -d ${2%%:*} ]] && {
325+
LOG "WARNING: --bind path $2 not found"
326+
GWARN "WARNING: --bind path $2 not found"
329327
}
330328
fi
329+
custom_fs_bindings+=("$2")
330+
shift 2
331331
}
332332
;;
333333
--user)

0 commit comments

Comments
 (0)