Skip to content

Commit

Permalink
Fix a memory leaking with CappedArrayPool
Browse files Browse the repository at this point in the history
  • Loading branch information
hadashiA committed Jul 13, 2023
1 parent c194894 commit e0be119
Showing 1 changed file with 1 addition and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -62,6 +62,7 @@ public void Return(T[] array)
var i = array.Length - 1;
lock (syncRoot)
{
Array.Clear(array);
if (tails[i] > 0)
tails[i] -= 1;
}
Expand Down

0 comments on commit e0be119

Please sign in to comment.