This adds locking around the connection to the manager, which ensures there are no race conditions between log messages being sent to the manager by the main thread, and profiling information being sent to the manager by the profiling communication background thread.
This adds locking around the connection to the manager, which ensures there are no race conditions between log messages being sent to the manager by the main thread, and profiling information being sent to the manager by the profiling communication background thread.