From 5e98347b313a5703a88d2c1fb12537565d426c1a Mon Sep 17 00:00:00 2001 From: Ghislain MARY Date: Tue, 3 Apr 2018 17:05:02 +0200 Subject: [PATCH] Add log when we cannot find the selected valid ICE pair in the case where it should be there (retrofit of commit 452234d4). --- src/nat/ice-agent.cpp | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/src/nat/ice-agent.cpp b/src/nat/ice-agent.cpp index 726312f9f..cbc74cd4a 100644 --- a/src/nat/ice-agent.cpp +++ b/src/nat/ice-agent.cpp @@ -317,10 +317,12 @@ void IceAgent::updateLocalMediaDescriptionFromIce (SalMediaDescription *desc) { } if (firstCl) result = !!ice_check_list_selected_valid_local_candidate(firstCl, &rtpCandidate, nullptr); - if (result) + if (result) { strncpy(desc->addr, rtpCandidate->taddr.ip, sizeof(desc->addr)); - else + } else { lWarning() << "If ICE has completed successfully, rtp_candidate should be set!"; + ice_dump_valid_list(firstCl); + } } strncpy(desc->ice_pwd, ice_session_local_pwd(iceSession), sizeof(desc->ice_pwd));