mirror of
https://gitlab.winehq.org/wine/wine-gecko.git
synced 2024-09-13 09:24:08 -07:00
Properly align pages allocated by GCHeap.
This commit is contained in:
parent
ddb6af4683
commit
9c6e4287f1
@ -84,7 +84,7 @@ public:
|
|||||||
Alloc(uint32_t pages)
|
Alloc(uint32_t pages)
|
||||||
{
|
{
|
||||||
void* p = malloc((pages + 1) * kNativePageSize);
|
void* p = malloc((pages + 1) * kNativePageSize);
|
||||||
p = (void*)(((int)(((char*)p) + kNativePageSize)) & (~0xfff));
|
p = (void*)(((int)(((char*)p) + kNativePageSize - 1)) & (~0xfff));
|
||||||
return p;
|
return p;
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -110,6 +110,7 @@ public:
|
|||||||
static inline void
|
static inline void
|
||||||
Free(void* p)
|
Free(void* p)
|
||||||
{
|
{
|
||||||
|
//free(p);
|
||||||
}
|
}
|
||||||
|
|
||||||
static inline GCHeap*
|
static inline GCHeap*
|
||||||
|
Loading…
Reference in New Issue
Block a user