Always clear buffers returned to the memory pool

Just a safety measure in case anything evades our 'flattening'. I don't
have any evidence that we're failing to clear something, but we want this
here as a safeguard.
This commit is contained in:
Ryan Nowak 2016-03-30 14:51:54 -07:00
parent b04bb124b0
commit 96e5c7b22e
1 changed files with 1 additions and 1 deletions

View File

@ -120,7 +120,7 @@ namespace Microsoft.AspNetCore.Mvc.ViewFeatures.Internal
for (var i = 0; i < _leased.Count; i++)
{
_viewBufferPool.Return(_leased[i]);
_viewBufferPool.Return(_leased[i], clearArray: true);
}
_leased.Clear();