fmod-gdextension
fmod-gdextension copied to clipboard
SegFault when a lot of Nodes are freed.
This one is a tricky issue.
When nodes have been freed from memory, our plugin just automatically detects when it happens and detaches the listeners/events. by the mean of is_instance_valid
.
Usually it's enough, but when a big chunk of memory has been freed, we literally no longer can access the address to the node and get a segfault.
The simple solution for it, should to connect to the signal tree_exited
so we can detach node at this moment instead of checking the pointer.