diff --git a/Lib/csharp/csharp.swg b/Lib/csharp/csharp.swg index dbc13a29f..dfff4b7a4 100644 --- a/Lib/csharp/csharp.swg +++ b/Lib/csharp/csharp.swg @@ -440,6 +440,7 @@ $1 = &temp; %} swigCMemOwn = false; } swigCPtr = IntPtr.Zero; + GC.SuppressFinalize(this); } %typemap(csdestruct_derived) SWIGTYPE { @@ -448,6 +449,7 @@ $1 = &temp; %} swigCMemOwn = false; } swigCPtr = IntPtr.Zero; + GC.SuppressFinalize(this); base.Dispose(); }