Manually unpinning a byte[] in C#?
问题 In the following code, it seems that the client.Connect.Receive is pinning the "byte[] result" permanently, causing the memory to never be freed (as it's always pinned). I'm looking for a way to tell C# that result no-longer needs to be pinned after it's usage in this.OnReceive, but I can't find the built-in function or keyword to do this. Does anyone know how I can get C# to unpin the byte[] array? (this is one of the sources of memory leaks in my C# application) this.m_TcpListener = new