wg_engine: fix a memory violation by a mistake

regresion by ac08a9d6e7

issue: https://github.com/thorvg/thorvg/issues/3241
This commit is contained in:
Hermet Park 2025-02-17 23:36:39 +09:00 committed by Hermet Park
parent 457c44c922
commit 65306d9b66

View file

@ -77,6 +77,7 @@ WgGeometryBufferPool* WgGeometryBufferPool::instance()
WgGeometryBufferPool::~WgGeometryBufferPool()
{
ARRAY_FOREACH(p, vbuffers) delete(*p);
//The indexed buffer may contain the vertex buffer, so free the memory in reverse order.
ARRAY_FOREACH(p, ibuffers) delete(*p);
ARRAY_FOREACH(p, vbuffers) delete(*p);
}