Merge pull request #5 from dgarske/fix_realloc

pull/6/head
Chris Conlon 2022-03-23 10:37:06 -06:00 committed by GitHub
commit 115cd3acf5
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 2 additions and 2 deletions

View File

@ -318,7 +318,7 @@ void *pvReturn = NULL;
if(pxLink->xBlockSize & xBlockAllocatedBit)
{
uint32_t blockSize = (pxLink->xBlockSize & ~xBlockAllocatedBit);
blockSize -= (xHeapStructSize + HEAP_CHECK_SIZE);
blockSize -= xHeapStructSize;
pvReturn = pvPortMalloc(xWantedSize);
if(pvReturn)
{

View File

@ -327,7 +327,7 @@ void *pvReturn = NULL;
if(pxLink->xBlockSize & xBlockAllocatedBit)
{
uint32_t blockSize = (pxLink->xBlockSize & ~xBlockAllocatedBit);
blockSize -= (uxHeapStructSize + HEAP_CHECK_SIZE);
blockSize -= uxHeapStructSize;
pvReturn = pvPortMalloc(xWantedSize);
if(pvReturn)
{