修复webrtcsession getIdentifier 为空的bug,导致GetAllSession webrtcsession的id 为空

This commit is contained in:
xiongguangjie
2022-09-07 13:58:26 +08:00
parent 4f47b7a5fe
commit 96c19ac85f
2 changed files with 2 additions and 6 deletions

View File

@@ -58,7 +58,6 @@ void WebRtcSession::onRecv(const Buffer::Ptr &buffer) {
//只允许寻找一次transport
_find_transport = false;
auto user_name = getUserName(buffer);
_identifier = to_string(getSock()->rawFD()) + '-' + user_name;
auto transport = WebRtcTransportManager::Instance().getItem(user_name);
CHECK(transport && transport->getPoller()->isCurrentThread());
transport->setSession(shared_from_this());
@@ -97,7 +96,5 @@ void WebRtcSession::onManager() {
}
}
std::string WebRtcSession::getIdentifier() const {
return _identifier;
}