mirror of
https://github.com/zeldaret/tp
synced 2026-05-22 22:44:28 -04:00
Couple sizeof(CMemBlock)s (#3143)
This commit is contained in:
committed by
GitHub
parent
bcd5a96391
commit
dabd6961a6
@@ -35,7 +35,7 @@ public:
|
||||
CMemBlock* getNextBlock() const { return mNext; }
|
||||
u32 getSize() const { return size; }
|
||||
u8 getGroupId() const { return mGroupId; }
|
||||
static CMemBlock* getBlock(void* data) { return (CMemBlock*)((uintptr_t)data + -0x10); }
|
||||
static CMemBlock* getBlock(void* data) { return (CMemBlock*)((uintptr_t)data + -sizeof(CMemBlock)); }
|
||||
|
||||
private:
|
||||
/* 0x0 */ u16 mMagic;
|
||||
|
||||
@@ -464,7 +464,7 @@ void JKRExpHeap::do_freeAll() {
|
||||
JKRHeap::callAllDisposer();
|
||||
mHeadFreeList = (CMemBlock*)mStart;
|
||||
mTailFreeList = mHeadFreeList;
|
||||
mHeadFreeList->initiate(NULL, NULL, mSize - 0x10, 0, 0);
|
||||
mHeadFreeList->initiate(NULL, NULL, mSize - sizeof(CMemBlock), 0, 0);
|
||||
mHeadUsedList = NULL;
|
||||
mTailUsedList = NULL;
|
||||
#if DEBUG
|
||||
|
||||
Reference in New Issue
Block a user