From cfac61e55b459526099b7b4ca623d5ac7cb2ba1a Mon Sep 17 00:00:00 2001 From: xia-chu <771730766@qq.com> Date: Fri, 22 Mar 2024 20:34:07 +0800 Subject: [PATCH] BugFix: prevent the player's configuration from being overridden in addStreamProxy --- server/WebApi.cpp | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/server/WebApi.cpp b/server/WebApi.cpp index 846f280a..9ea3681d 100755 --- a/server/WebApi.cpp +++ b/server/WebApi.cpp @@ -584,8 +584,10 @@ void addStreamProxy(const string &vhost, const string &app, const string &stream //添加拉流代理 auto player = s_player_proxy.make(key, vhost, app, stream, option, retry_count); - // 先透传参数 - player->mINI::operator=(args); + // 先透传拷贝参数 + for (auto &pr : args) { + (*player)[pr.first] = pr.second; + } //指定RTP over TCP(播放rtsp时有效) (*player)[Client::kRtpType] = rtp_type;