1
0
mirror of https://github.com/godotengine/godot.git synced 2025-11-05 12:10:55 +00:00

C#: Fix crash when disposing Reference on domain finalize

This commit is contained in:
Ignacio Etcheverry
2018-10-25 17:21:42 +02:00
parent 7a42df3626
commit b42f7b7fae

View File

@@ -1407,6 +1407,8 @@ bool CSharpInstance::_unreference_owner_unsafe() {
if (!unsafe_referenced)
return false; // Already unreferenced
unsafe_referenced = false;
// Called from CSharpInstance::mono_object_disposed() or ~CSharpInstance()
// Unsafe refcount decrement. The managed instance also counts as a reference.