mirror of
https://codeberg.org/libreboot/lbmk.git
synced 2026-07-11 05:52:36 +02:00
get.sh: Make xbmkget err on exiting the loop check
The idea in this function is that if a file or repo is successfully handled, a return will be performed from the loop. If the loop exits for any reason, an error is thrown. The current code is probably fine, but I can forsee future modifications possibly causing bugs here. Make it unambiguous, by always throwing an error if execution reaches the end of the function. Signed-off-by: Leah Rowe <leah@libreboot.org>
This commit is contained in:
+2
-1
@@ -87,7 +87,8 @@ xbmkget()
|
||||
for url in "$2" "$3"; do
|
||||
[ -n "$url" ] && try_file "$url" "$@" && \
|
||||
eval "[ -$echk \"$4\" ] && return 0"
|
||||
done && err "$1 $2 $3 $4: not downloaded"; :
|
||||
done
|
||||
err "$1 $2 $3 $4: not downloaded"; :
|
||||
}
|
||||
|
||||
try_file()
|
||||
|
||||
Reference in New Issue
Block a user