summaryrefslogtreecommitdiff
path: root/modules/mono/glue/Managed/Files/Dictionary.cs
diff options
context:
space:
mode:
Diffstat (limited to 'modules/mono/glue/Managed/Files/Dictionary.cs')
-rw-r--r--modules/mono/glue/Managed/Files/Dictionary.cs3
1 files changed, 3 insertions, 0 deletions
diff --git a/modules/mono/glue/Managed/Files/Dictionary.cs b/modules/mono/glue/Managed/Files/Dictionary.cs
index 7695f03cd6..fb4521065f 100644
--- a/modules/mono/glue/Managed/Files/Dictionary.cs
+++ b/modules/mono/glue/Managed/Files/Dictionary.cs
@@ -54,6 +54,9 @@ namespace Godot.Collections
internal IntPtr GetPtr()
{
+ if (disposed)
+ throw new ObjectDisposedException(GetType().FullName);
+
return safeHandle.DangerousGetHandle();
}