Skip to content

Commit

Permalink
[apps] Added support for adapter parameter in caller mode (#2202)
Browse files Browse the repository at this point in the history
  • Loading branch information
ethouris committed Dec 6, 2021
1 parent c9a8db7 commit 40b5129
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 7 deletions.
4 changes: 2 additions & 2 deletions apps/transmitmedia.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -377,9 +377,9 @@ void SrtCommon::OpenClient(string host, int port)
{
PrepareClient();

if ( m_outgoing_port )
if (m_outgoing_port || m_adapter != "")
{
SetupAdapter("", m_outgoing_port);
SetupAdapter(m_adapter, m_outgoing_port);
}

ConnectClient(host, port);
Expand Down
10 changes: 5 additions & 5 deletions testing/testmedia.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -881,9 +881,9 @@ void SrtCommon::OpenClient(string host, int port)
{
PrepareClient();

if (m_outgoing_port)
if (m_outgoing_port || m_adapter != "")
{
SetupAdapter("", m_outgoing_port);
SetupAdapter(m_adapter, m_outgoing_port);
}

ConnectClient(host, port);
Expand Down Expand Up @@ -2580,10 +2580,10 @@ void SrtModel::Establish(std::string& w_name)
Verb() << "NO STREAM ID for SRT connection";
}

if (m_outgoing_port)
if (m_outgoing_port || m_adapter != "")
{
Verb() << "Setting outgoing port: " << m_outgoing_port;
SetupAdapter("", m_outgoing_port);
Verb() << "Setting outgoing port: " << m_outgoing_port << " adapter:" << m_adapter;
SetupAdapter(m_adapter, m_outgoing_port);
}

ConnectClient(m_host, m_port);
Expand Down

0 comments on commit 40b5129

Please sign in to comment.