Update minimal_heap_implementation.inl

This commit is contained in:
2026-06-11 16:30:04 +02:00
parent df3e59cd1f
commit 128d0e6a8d

View File

@@ -588,7 +588,7 @@ MIHP_HeapMemoryAreaHeader* MIHP_CreateHeapMemoryArea(MIHP_Heap* heap, size_t req
effectiveSize = MIHP_MAX(effectiveSize, heap->Config.MinMemoryAreaSize);
effectiveSize = MIHP_MIN(effectiveSize, heap->Config.MaxMemoryAreaSize);
if (heap->Stats.TotalSize + requestedSize > heap->Config.MaxHeapSize)
if (heap->Stats.TotalSize + effectiveSize > heap->Config.MaxHeapSize)
return NULL;
size_t actualSize = 0;