mirror of
https://github.com/OpenMW/openmw.git
synced 2025-02-28 14:39:43 +00:00
Allow BSA string tables to contain padding
This commit is contained in:
parent
58aeb81e46
commit
4d717ade6c
1 changed files with 6 additions and 5 deletions
|
@ -144,8 +144,9 @@ namespace Bsa
|
|||
input.read(reinterpret_cast<char*>(&file.mOffset), 4);
|
||||
}
|
||||
}
|
||||
|
||||
if (mHeader.mFolderNamesLength != 0)
|
||||
fail("Failed to read folder names: " + std::to_string(mHeader.mFolderNamesLength) + " bytes remaining");
|
||||
input.ignore(mHeader.mFolderNamesLength);
|
||||
|
||||
if (input.bad())
|
||||
fail("Failed to read compressed BSA file records: input error");
|
||||
|
@ -172,13 +173,13 @@ namespace Bsa
|
|||
file.mName.insert(file.mName.begin() + folder.mName.size(), '\\');
|
||||
}
|
||||
}
|
||||
|
||||
if (input.bad())
|
||||
fail("Failed to read compressed BSA filenames: input error");
|
||||
}
|
||||
|
||||
if (mHeader.mFileNamesLength != 0)
|
||||
fail("Failed to read file names: " + std::to_string(mHeader.mFileNamesLength) + " bytes remaining");
|
||||
input.ignore(mHeader.mFileNamesLength);
|
||||
|
||||
if (input.bad())
|
||||
fail("Failed to read compressed BSA filenames: input error");
|
||||
|
||||
for (auto& [folder, filelist] : folders)
|
||||
{
|
||||
|
|
Loading…
Reference in a new issue