[fix] stop devices control and capture when client peer destroyed

This commit is contained in:
dijunkun
2025-11-11 00:59:54 +08:00
parent 2ee3e93afe
commit 910cc9b587

View File

@@ -1191,6 +1191,10 @@ void Render::CleanupPeers() {
LOG_INFO("[{}] Leave connection [{}]", client_id_, client_id_);
LeaveConnection(peer_, client_id_);
is_client_mode_ = false;
StopScreenCapturer();
StopSpeakerCapturer();
StopMouseController();
StopKeyboardCapturer();
LOG_INFO("Destroy peer [{}]", client_id_);
DestroyPeer(&peer_);
}