mirror of
https://github.com/ossrs/srs.git
synced 2025-03-09 15:49:59 +00:00
RTC: Support address switch
This commit is contained in:
parent
38f935ead8
commit
5f88dc357e
3 changed files with 21 additions and 0 deletions
|
@ -494,6 +494,14 @@ bool SrsRtcServer::insert_into_id_sessions(const string& peer_id, SrsRtcConnecti
|
|||
return map_id_session.insert(make_pair(peer_id, session)).second;
|
||||
}
|
||||
|
||||
void SrsRtcServer::remove_id_sessions(const string& peer_id)
|
||||
{
|
||||
std::map<std::string, SrsRtcConnection*>::iterator it;
|
||||
if ((it = map_id_session.find(peer_id)) != map_id_session.end()) {
|
||||
map_id_session.erase(it);
|
||||
}
|
||||
}
|
||||
|
||||
void SrsRtcServer::check_and_clean_timeout_session()
|
||||
{
|
||||
map<string, SrsRtcConnection*>::iterator iter = map_username_session.begin();
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue