Files
ResInsight/Fwk
Magne Sjaastad f7ccfcfff6 #14182 Fix stack overflow when destroying deep AABB bounding box trees
The bounding box tree is destroyed by deleteInternalNodesBottomUp, which
recursed once per tree level. For deep or unbalanced trees this overflowed
the call stack during project close (RigMainGrid destruction).

Replace the recursion with an explicit stack. Deleting an internal node does
not touch its children, so the child pointers are read before the node is
deleted and the deletion order is irrelevant. Leaf nodes remain pooled and
are not deleted individually.
2026-06-10 08:57:39 +02:00
..