Commit 8dc50201 authored by Vitaly Lipatov's avatar Vitaly Lipatov

rpmgs: remove file if download is failed

parent 431d88c8
......@@ -66,7 +66,10 @@ get_archive()
WEXT=`basename "$URL"`
[ -n "$FORCEDOWNLOAD" ] && docmd rm -f "$WEXT.$1"
test -f "$WEXT.$1" && echog "$WEXT.$1 already exists" && return
download_url "$URL.$1" || return
if ! download_url "$URL.$1" ; then
rm -f "$WEXT.$1"
return 1
fi
erc repack "$WEXT.$1" "$(basename "$GETSOURCE")"
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment