diff options
author | Ladislav Zezula <zezula@volny.cz> | 2024-04-21 18:22:59 +0200 |
---|---|---|
committer | Ladislav Zezula <zezula@volny.cz> | 2024-04-21 18:22:59 +0200 |
commit | 3643858d00d26165404837a1f0f7640a84873c30 (patch) | |
tree | 7eae2c80b81a0132f60eb161d758d306f1686595 /test/StormTest.cpp | |
parent | 34a29066eaf9050ba88fd02cd8a370ac0fc7c7ea (diff) |
Fixed reading big files from non-corrupt MPQs
Diffstat (limited to 'test/StormTest.cpp')
-rwxr-xr-x | test/StormTest.cpp | 11 |
1 files changed, 4 insertions, 7 deletions
diff --git a/test/StormTest.cpp b/test/StormTest.cpp index e8c9bd5..540557a 100755 --- a/test/StormTest.cpp +++ b/test/StormTest.cpp @@ -3787,16 +3787,13 @@ static DWORD TestReplaceFile(LPCTSTR szMpqPlainName, LPCTSTR szFilePlainName, LP static void Test_PlayingSpace()
{
- HANDLE hFile = NULL;
+ SFILE_FIND_DATA sf;
HANDLE hMpq = NULL;
- if(SFileOpenArchive(_T("(4)Duskwood.w3m"), 0, 0, &hMpq))
+ if(SFileOpenArchive(_T("e:\\poc11"), 0, 0, &hMpq))
{
- if(SFileOpenFileEx(hMpq, "war3map.j", 0, &hFile))
- {
- SFileSetFileLocale(hFile, 1033);
- SFileCloseFile(hFile);
- }
+ SFileFindFirstFile(hMpq, "*", &sf, NULL);
+ SFileAddWave(hMpq, _T("e:\\Ladik\\Incoming\\poc11"), "poc11", MPQ_FILE_FIX_KEY, 1);
SFileCloseArchive(hMpq);
}
}
|