mirror of
https://github.com/TES3MP/openmw-tes3mp.git
synced 2025-02-28 13:09:40 +00:00
Fixed warnings reported by GCC
This commit is contained in:
parent
d55cc4d3ea
commit
4c499983ca
1 changed files with 12 additions and 15 deletions
|
@ -127,7 +127,7 @@ void TES4BSAFile::readHeader()
|
||||||
|
|
||||||
// Get essential header numbers
|
// Get essential header numbers
|
||||||
//size_t dirsize, filenum;
|
//size_t dirsize, filenum;
|
||||||
std::uint32_t archiveFlags, folderCount, fileCount, totalFileNameLength;
|
std::uint32_t archiveFlags, folderCount, totalFileNameLength;
|
||||||
{
|
{
|
||||||
// First 36 bytes
|
// First 36 bytes
|
||||||
std::uint32_t header[9];
|
std::uint32_t header[9];
|
||||||
|
@ -154,7 +154,6 @@ void TES4BSAFile::readHeader()
|
||||||
//
|
//
|
||||||
archiveFlags = header[3];
|
archiveFlags = header[3];
|
||||||
folderCount = header[4];
|
folderCount = header[4];
|
||||||
fileCount = header[5];
|
|
||||||
totalFileNameLength = header[7];
|
totalFileNameLength = header[7];
|
||||||
|
|
||||||
mCompressedByDefault = (archiveFlags & 0x4) != 0;
|
mCompressedByDefault = (archiveFlags & 0x4) != 0;
|
||||||
|
@ -381,23 +380,21 @@ BsaVersion TES4BSAFile::detectVersion(std::string filePath)
|
||||||
return BSAVER_UNKNOWN;
|
return BSAVER_UNKNOWN;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
// Get essential header numbers
|
// Get essential header numbers
|
||||||
size_t dirsize, filenum;
|
|
||||||
{
|
// First 12 bytes
|
||||||
// First 12 bytes
|
uint32_t head[3];
|
||||||
uint32_t head[3];
|
|
||||||
|
|
||||||
input.read(reinterpret_cast<char*>(head), 12);
|
input.read(reinterpret_cast<char*>(head), 12);
|
||||||
|
|
||||||
if (head[0] == static_cast<uint32_t>(BSAVER_TES3)) {
|
if (head[0] == static_cast<uint32_t>(BSAVER_TES3)) {
|
||||||
return BSAVER_TES3;
|
return BSAVER_TES3;
|
||||||
}
|
|
||||||
|
|
||||||
if (head[0] = static_cast<uint32_t>(BSAVER_TES4PLUS)) {
|
|
||||||
return BSAVER_TES4PLUS;
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if (head[0] == static_cast<uint32_t>(BSAVER_TES4PLUS)) {
|
||||||
|
return BSAVER_TES4PLUS;
|
||||||
|
}
|
||||||
|
|
||||||
return BSAVER_UNKNOWN;
|
return BSAVER_UNKNOWN;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue