fixing missing deletion of wrong-md5 partial file
This commit is contained in:
@@ -180,6 +180,8 @@ for ((i = 0; i < ${#SMALLNAME[*]}; i++)); do
|
|||||||
elif [ -e $SMALLPATH ] && [ $(du $SMALLPATH | awk -F" " '{ print $1 }') == $SMALLSIZE ] && [ $(md5sum $SMALLPATH | awk -F" " '{ print $1 }') != $SMALLMD5 ]; then
|
elif [ -e $SMALLPATH ] && [ $(du $SMALLPATH | awk -F" " '{ print $1 }') == $SMALLSIZE ] && [ $(md5sum $SMALLPATH | awk -F" " '{ print $1 }') != $SMALLMD5 ]; then
|
||||||
echo "[ERROR] MD5 is different but file has same size."
|
echo "[ERROR] MD5 is different but file has same size."
|
||||||
echo "[INFO] Deleting file and starting new download."
|
echo "[INFO] Deleting file and starting new download."
|
||||||
|
checkwait
|
||||||
|
rm $SMALLPATH
|
||||||
wget -O $SMALLPATH $SMALLURL
|
wget -O $SMALLPATH $SMALLURL
|
||||||
|
|
||||||
# File already exists, has correct size, and has correct MD5
|
# File already exists, has correct size, and has correct MD5
|
||||||
|
|||||||
Reference in New Issue
Block a user