Fixed a bug with asset loader

This commit is contained in:
2024-11-25 23:40:18 -06:00
parent 91caebd385
commit 98f2f3e955
10 changed files with 165 additions and 12 deletions

View File

@@ -201,7 +201,7 @@ size_t AssetDataLoader::skip(const size_t &n) {
size_t n2, n3, n4;
n4 = n;
while(n4 != 0) {
n2 = Math::min<size_t>(n, ASSET_LOADER_BUFFER_SIZE);
n2 = Math::min<size_t>(n4, ASSET_LOADER_BUFFER_SIZE);
n3 = this->read(dumpBuffer, n2);
assertTrue(n3 == n2, "Failed to skip bytes!");
n4 -= n3;