summaryrefslogtreecommitdiff
path: root/include/lib.sh
diff options
context:
space:
mode:
authorLeah Rowe <leah@libreboot.org>2024-06-09 11:04:25 +0100
committerLeah Rowe <leah@libreboot.org>2024-06-09 11:04:25 +0100
commitf3f5b99cecefe7d768173988f021490a50a1cac3 (patch)
tree38b465d30fee5867fe3dfa19a393881165c06a47 /include/lib.sh
parent3440e1f651623cd909c6a2a17a024e754950a61b (diff)
lib.sh: hide stderr on download()
on the initial check, the output is confusing because it will say "checksum verification failed" if the file doesn't already exist, but then goes to download. only say checksum failed if a download occured, and the check failed, otherwise report nothing except that the file already exists. this will not reduce the ability to debug issues later on, and it will reduce the amount of confusion for users. Signed-off-by: Leah Rowe <leah@libreboot.org>
Diffstat (limited to 'include/lib.sh')
-rwxr-xr-xinclude/lib.sh2
1 files changed, 1 insertions, 1 deletions
diff --git a/include/lib.sh b/include/lib.sh
index 5244ce45..f72c785e 100755
--- a/include/lib.sh
+++ b/include/lib.sh
@@ -230,7 +230,7 @@ singletree()
download()
{
dl_fail="y" # 1 url, 2 url backup, 3 destination, 4 checksum
- vendor_checksum "$4" "$3" || dl_fail="n"
+ vendor_checksum "$4" "$3" 2>/dev/null || dl_fail="n"
[ "$dl_fail" = "n" ] && e "$3" f && return 0
x_ mkdir -p "${3%/*}" && for url in "$1" "$2"; do
[ "$dl_fail" = "n" ] && break