mirror of
https://github.com/ladislav-zezula/StormLib.git
synced 2026-01-20 14:47:22 +01:00
+ Fixed bug in opening SQP archives
+ More efficient version of GetNearestPowerOfTwo
This commit is contained in:
@@ -701,7 +701,7 @@ static TMPQHash * DefragmentHashTable(
|
||||
|
||||
// Calculate how many entries in the hash table we really need
|
||||
dwFirstFreeEntry = (DWORD)(pTarget - pHashTable);
|
||||
dwNewTableSize = GetHashTableSizeForFileCount(dwFirstFreeEntry);
|
||||
dwNewTableSize = GetNearestPowerOfTwo(dwFirstFreeEntry);
|
||||
|
||||
// Fill the rest with entries that look like deleted
|
||||
pHashTableEnd = pHashTable + dwNewTableSize;
|
||||
|
||||
Reference in New Issue
Block a user