Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Race condition #93

Open
chuckleplant opened this issue Jan 19, 2017 · 0 comments
Open

Race condition #93

chuckleplant opened this issue Jan 19, 2017 · 0 comments

Comments

@chuckleplant
Copy link
Contributor

chuckleplant commented Jan 19, 2017

Great lib!

Found this:

The deque elements in Connection are accessed both by the Server thread and the one that enqueues via Server::send. This is a race condition as std::deque is not thread safe.

Hotfix: Use a mutex in Server both in the Connection::update and the Connection::send calls.

Betterfix: Use this lock free FIFO structure

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

No branches or pull requests

1 participant