You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
When calling a destructor for a Solution object via soln_del using the clib API, associated ThermoPhase, Kinetics and Transport objects are deallocated. As integer entry numbers ('handles') are not available, the destructor relies on Cabinet<M>::index, which returns the last entry of a reverse lookup table. There is no guarantee that the correct entry is removed, leading to potentially unpredictable behavior and memory leaks.
Problem description
When calling a destructor for a
Solution
object viasoln_del
using theclib
API, associatedThermoPhase
,Kinetics
andTransport
objects are deallocated. As integer entry numbers ('handles') are not available, the destructor relies onCabinet<M>::index
, which returns the last entry of a reverse lookup table. There is no guarantee that the correct entry is removed, leading to potentially unpredictable behavior and memory leaks.System information
Additional context
The text was updated successfully, but these errors were encountered: