Commit c8c9ef1c authored by Simon Morlat's avatar Simon Morlat

specify role immediately when asking for an ice restart.

parent af6d6513
......@@ -331,7 +331,7 @@ MS2_PUBLIC const char * ice_session_remote_pwd(const IceSession *session);
MS2_PUBLIC IceSessionState ice_session_state(const IceSession *session);
/**
* Gte the role of the agent for an ICE session.
* Get the role of the agent for an ICE session.
*
* @param session A pointer to a session
* @return The role of the agent for the session
......@@ -502,7 +502,7 @@ MS2_PUBLIC void ice_session_select_candidates(IceSession *session);
*
* @param session A pointer to a session
*/
MS2_PUBLIC void ice_session_restart(IceSession *session);
MS2_PUBLIC void ice_session_restart(IceSession *session, IceRole role);
/**
* Get the state of an ICE check list.
......
......@@ -3109,8 +3109,7 @@ static void ice_check_list_restart(IceCheckList *cl)
memset(&cl->nomination_delay_start_time, 0, sizeof(cl->nomination_delay_start_time));
}
void ice_session_restart(IceSession *session)
{
void ice_session_restart(IceSession *session, IceRole role){
int i;
ms_warning("ICE session restart");
......@@ -3132,6 +3131,7 @@ void ice_session_restart(IceSession *session)
if (session->streams[i] != NULL)
ice_check_list_restart(session->streams[i]);
}
ice_session_set_role(session, role);
}
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment