SNIPacketRelease() private method

private SNIPacketRelease ( IntPtr pPacket ) : void
pPacket IntPtr
return void
Beispiel #1
0
        protected override bool ReleaseHandle()
        {
            IntPtr handle = base.handle;

            base.handle = IntPtr.Zero;
            if (IntPtr.Zero != handle)
            {
                SNINativeMethodWrapper.SNIPacketRelease(handle);
            }
            return(true);
        }
        override protected bool ReleaseHandle()
        {
            // NOTE: The SafeHandle class guarantees this will be called exactly once.
            IntPtr ptr = base.handle;

            base.handle = IntPtr.Zero;
            if (IntPtr.Zero != ptr)
            {
                SNINativeMethodWrapper.SNIPacketRelease(ptr);
            }
            return(true);
        }
 internal override void ReleasePacket(object syncReadPacket) => SNINativeMethodWrapper.SNIPacketRelease((IntPtr)syncReadPacket);