Skip to content

Conversation

@Lil-Duckling-22
Copy link

Fix race condition in events.Producer.Broadcast that caused panics when subscriptions were cancelled concurrently with broadcasts. Copy subscription list under lock and add recover() to handle closed channel panics.

Without this fix, the application crashes with "send on closed channel" panic when Next() closes a subscription channel while Broadcast sends to it.

Fix race condition in events.Producer.Broadcast that caused panics when
subscriptions were cancelled concurrently with broadcasts. Copy subscription
list under lock and add recover() to handle closed channel panics.

Without this fix, the application crashes with "send on closed channel"
panic when Next() closes a subscription channel while Broadcast sends to it.
@CLAassistant
Copy link

CLAassistant commented Dec 29, 2025

CLA assistant check
All committers have signed the CLA.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants