Fixed allocation alignment problem: checking in for jim_nance@yahoo.com

b=85890 r=attinasi sr=alecf
This commit is contained in:
attinasi%netscape.com 2001-06-26 01:19:05 +00:00
Родитель 78acc02575
Коммит e2467c9201
2 изменённых файлов: 8 добавлений и 8 удалений

Просмотреть файл

@ -558,8 +558,8 @@ FrameArena::AllocateFrame(size_t aSize, void** aResult)
{
void* result = nsnull;
// Round size to multiple of 4
aSize = PR_ROUNDUP(aSize, 4);
// Ensure we have correct alignment for pointers. Important for Tru64
aSize = PR_ROUNDUP(aSize, sizeof(void*));
// Check recyclers first
if (aSize < gMaxRecycledSize) {
@ -585,8 +585,8 @@ FrameArena::AllocateFrame(size_t aSize, void** aResult)
nsresult
FrameArena::FreeFrame(size_t aSize, void* aPtr)
{
// Round size to multiple of 4
aSize = PR_ROUNDUP(aSize, 4);
// Ensure we have correct alignment for pointers. Important for Tru64
aSize = PR_ROUNDUP(aSize, sizeof(void*));
// See if it's a size that we recycle
if (aSize < gMaxRecycledSize) {

Просмотреть файл

@ -558,8 +558,8 @@ FrameArena::AllocateFrame(size_t aSize, void** aResult)
{
void* result = nsnull;
// Round size to multiple of 4
aSize = PR_ROUNDUP(aSize, 4);
// Ensure we have correct alignment for pointers. Important for Tru64
aSize = PR_ROUNDUP(aSize, sizeof(void*));
// Check recyclers first
if (aSize < gMaxRecycledSize) {
@ -585,8 +585,8 @@ FrameArena::AllocateFrame(size_t aSize, void** aResult)
nsresult
FrameArena::FreeFrame(size_t aSize, void* aPtr)
{
// Round size to multiple of 4
aSize = PR_ROUNDUP(aSize, 4);
// Ensure we have correct alignment for pointers. Important for Tru64
aSize = PR_ROUNDUP(aSize, sizeof(void*));
// See if it's a size that we recycle
if (aSize < gMaxRecycledSize) {