diff --git a/Source/OpenTK/ContextHandle.cs b/Source/OpenTK/ContextHandle.cs index 54e7b7c0..6c98ae30 100644 --- a/Source/OpenTK/ContextHandle.cs +++ b/Source/OpenTK/ContextHandle.cs @@ -52,7 +52,7 @@ namespace OpenTK public static implicit operator IntPtr(ContextHandle c) { - return c.handle; + return c != null ? c.handle : IntPtr.Zero; } public static implicit operator ContextHandle(IntPtr p)