mirror of
https://github.com/oliverbooth/VpSharp
synced 2024-11-09 23:15:41 +00:00
Suppress unlikely null value
This commit is contained in:
parent
6a16ef6097
commit
cb232cd0d3
@ -77,7 +77,7 @@ internal sealed class Connection : IDisposable
|
||||
public static nint CreateNative(nint vpConnection, nint context)
|
||||
{
|
||||
GCHandle contextHandle = GCHandle.FromIntPtr(context);
|
||||
var connection = new Connection(vpConnection, contextHandle.Target);
|
||||
var connection = new Connection(vpConnection, contextHandle.Target!);
|
||||
GCHandle handle = GCHandle.Alloc(connection, GCHandleType.Normal);
|
||||
var ptr = GCHandle.ToIntPtr(handle);
|
||||
return ptr;
|
||||
|
Loading…
Reference in New Issue
Block a user