Fix up the synchronization in the CodewindManager class so that it does not have its own lock and the CodewindConnectionManager lock at the same time.
Fix up the synchronization in the CodewindManager class so that it does not have its own lock and the CodewindConnectionManager lock at the same time.