Skip to content

#14423 Fix crash when closing summary cases referred by a delta ensemble - #14424

Draft
magnesj wants to merge 1 commit into
OPM:devfrom
magnesj:fix-14423-delta-ensemble-close-cases
Draft

#14423 Fix crash when closing summary cases referred by a delta ensemble#14424
magnesj wants to merge 1 commit into
OPM:devfrom
magnesj:fix-14423-delta-ensemble-close-cases

Conversation

@magnesj

@magnesj magnesj commented Jul 31, 2026

Copy link
Copy Markdown
Member

Fixes #14423

Problem

RimSummaryCaseMainCollection::allSummaryCases() includes the derived cases of a delta ensemble. When a source case is removed, the delta ensemble recreates its derived cases and deletes the ones no longer in use. Those objects are still present in the list being removed, so RicCloseSummaryCaseFeature::deleteSummaryCases passes dangling pointers to AsyncPdmObjectVectorDeleter, crashing in PdmObjectHandle::prepareForDelete().

Fix

Use guarded caf::PdmPointer in removeCases() to skip cases deleted as a side effect, and return only the surviving cases. Adds a unit test that reproduces the crash.

…semble

Removing a source case makes a delta ensemble recreate and delete its derived cases. Those cases are part of the list being removed, leaving dangling pointers that crash in PdmObjectHandle::prepareForDelete(). Use guarded pointers and return only the surviving cases.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Crash when closing all summary cases with a delta ensemble

1 participant