Fixed Race Condition in ServerConnection