diff --git a/Generals/Code/Libraries/Source/WWVegas/WW3D2/sortingrenderer.cpp b/Generals/Code/Libraries/Source/WWVegas/WW3D2/sortingrenderer.cpp index a2ce1c4f9e..f8b0cf9a15 100644 --- a/Generals/Code/Libraries/Source/WWVegas/WW3D2/sortingrenderer.cpp +++ b/Generals/Code/Libraries/Source/WWVegas/WW3D2/sortingrenderer.cpp @@ -442,6 +442,7 @@ void SortingRendererClass::Insert_To_Sorting_Pool(SortingNodeStruct* state) { if (overlapping_node_count>=MAX_OVERLAPPING_NODES) { Release_Refs(state); + delete state; WWASSERT(0); return; } diff --git a/GeneralsMD/Code/Libraries/Source/WWVegas/WW3D2/sortingrenderer.cpp b/GeneralsMD/Code/Libraries/Source/WWVegas/WW3D2/sortingrenderer.cpp index 691ad41492..2bf6401a9b 100644 --- a/GeneralsMD/Code/Libraries/Source/WWVegas/WW3D2/sortingrenderer.cpp +++ b/GeneralsMD/Code/Libraries/Source/WWVegas/WW3D2/sortingrenderer.cpp @@ -344,6 +344,7 @@ void SortingRendererClass::Insert_To_Sorting_Pool(SortingNodeStruct* state) { if (overlapping_node_count>=MAX_OVERLAPPING_NODES) { Release_Refs(state); + delete state; WWASSERT(0); return; }