Skip to content

Conversation

@adrian-niculescu
Copy link
Contributor

@adrian-niculescu adrian-niculescu commented Nov 24, 2025

Fixed data race in CameraEventsDispatchHandler where callback methods accessed handlers without synchronization while registerHandler/unregisterHandler were @Synchronized

Replaced mutableSetOf with CopyOnWriteArraySet for thread-safe iteration

Considered val handlersCopy = synchronized(handlers) { handlers.toMutableSet() } but CopyOnWriteArraySet is cleaner and more efficient for this use case (infrequent writes, concurrent reads).

@changeset-bot
Copy link

changeset-bot bot commented Nov 24, 2025

🦋 Changeset detected

Latest commit: 2b3138b

The changes in this PR will be included in the next version bump.

This PR includes changesets to release 1 package
Name Type
client-sdk-android Patch

Not sure what this means? Click here to learn what changesets are.

Click here if you're a maintainer who wants to add another changeset to this PR

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.

1 participant