Anton Zhvakin
Anton Zhvakin
`CppServer::Asio::Timer::Cancel` method must be called from its `io_context`, otherwise there is a data race. https://www.boost.org/doc/libs/1_75_0/doc/html/boost_asio/reference/system_timer.html#boost_asio.reference.system_timer.thread_safety Or mark `CppServer::Asio::Timer` as not thread-safe. P.S. I highly recommend to test all of your...
`_server->_bytes_sent += sent;` and `_server->_bytes_received += received;` could be called from different sockets on different threads.
Testing an app built by clang with thread sanitizer showed a data race in `ssl_client.cpp`: Imagine that while receiving data, an error occurs, it causes calling `Disconnect`, that causes calling...
Now output stream operator includes a set of `if` statements, which might be inefficient if there are many different enum values. It could be much better if it's replaced by...