Skip to content

Fix leak and race condition with EventPipeBufferList #12007

@sywhang

Description

@sywhang

EventPipeBufferList has a potential leak under EventPipeBufferManager::DeAllocateBuffers(), and a potential race condition where WriteEvent may set the flag to indicate a buffer is in use when another thread is trying to free the buffers after checking that they aren't in use. So we should probably protect that flag with a lock to prevent this.

Some background info (comment from Noah):
dotnet/coreclr#21817 (comment)

Metadata

Metadata

Assignees

Type

No type

Projects

No projects

Milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions