[Scummvm-git-logs] scummvm master -> af038e3317a2beafbb44ea40990f19a39057bf34
sev-
noreply at scummvm.org
Sat Jul 9 11:56:07 UTC 2022
This automated email contains information about 1 new commit which have been
pushed to the 'scummvm' repo located at https://github.com/scummvm/scummvm .
Summary:
af038e3317 GUI: Check downloaded icon file sizes. Fixes bug #13566
Commit: af038e3317a2beafbb44ea40990f19a39057bf34
https://github.com/scummvm/scummvm/commit/af038e3317a2beafbb44ea40990f19a39057bf34
Author: Eugene Sandulenko (sev at scummvm.org)
Date: 2022-07-09T13:54:49+02:00
Commit Message:
GUI: Check downloaded icon file sizes. Fixes bug #13566
Changed paths:
gui/downloadiconsdialog.cpp
diff --git a/gui/downloadiconsdialog.cpp b/gui/downloadiconsdialog.cpp
index 063f1da0445..b3d164a39d4 100644
--- a/gui/downloadiconsdialog.cpp
+++ b/gui/downloadiconsdialog.cpp
@@ -376,7 +376,7 @@ void DownloadIconsDialog::calculateList() {
return;
}
- // Scan all files in iconspath and remove present ones from the
+ // Scan all files in iconspath and remove present and incomplete ones from the
// donwloaded files list
Common::FSDirectory *iconDir = new Common::FSDirectory(iconsPath);
@@ -386,8 +386,11 @@ void DownloadIconsDialog::calculateList() {
for (auto ic = iconFiles.begin(); ic != iconFiles.end(); ++ic) {
Common::String fname = (*ic)->getName();
+ Common::SeekableReadStream *str = (*ic)->createReadStream();
+ uint32 size = str->size();
+ delete str;
- if (g_state->fileHash.contains(fname))
+ if (g_state->fileHash.contains(fname) && size == g_state->fileHash[fname])
g_state->fileHash.erase(fname);
}
More information about the Scummvm-git-logs
mailing list