diff --git a/src/jamidht/connectionmanager.cpp b/src/jamidht/connectionmanager.cpp index 0f93f54b056106477abc4d9904e6efd6aac2aa0e..27459ab8d074062b8319e705ea2d9090860cb778 100644 --- a/src/jamidht/connectionmanager.cpp +++ b/src/jamidht/connectionmanager.cpp @@ -611,7 +611,7 @@ ConnectionManager::Impl::onRequestStartIce(const PeerConnectionRequest& req) } auto sdp = IceTransport::parse_SDP(req.ice_msg, *ice); - auto hasPubIp = hasPublicIp(sdp); + answerTo(*ice, req.id, req.from); if (not ice->startIce({sdp.rem_ufrag, sdp.rem_pwd}, sdp.rem_candidates)) { JAMI_ERR("[Account:%s] start ICE failed - fallback to TURN", account.getAccountID().c_str()); ice = nullptr; @@ -619,9 +619,6 @@ ConnectionManager::Impl::onRequestStartIce(const PeerConnectionRequest& req) connReadyCb_(req.from, "", nullptr); return; } - - if (hasPubIp) - answerTo(*ice, req.id, req.from); } void @@ -640,11 +637,6 @@ ConnectionManager::Impl::onRequestOnNegoDone(const PeerConnectionRequest& req) return; } - auto sdp = IceTransport::parse_SDP(req.ice_msg, *ice); - auto hasPubIp = hasPublicIp(sdp); - if (!hasPubIp) - answerTo(*ice, req.id, req.from); - // Build socket auto endpoint = std::make_unique<IceSocketEndpoint>(std::shared_ptr<IceTransport>( std::move(ice)),