Commit 1bfac496 authored by Committed by Olivier Crête
conncheck: fix try-alternate on tcp turn sockets
In OC2007R2 compatibility mode, we observed the behaviour of a skype turn server, when returning code 300 (try-alternate) stun error on its tls connections. This value is returned apparently when the turn server is overloaded already. We noticed that the actual code in priv_handle_turn_alternate_server() cannot handle a non-udp turn server, because a tcp one would require to create a new socket. But, even when creating such a new socket stack (tcp-bsd socket + pseudossl socket), libnice still fails to establish a new connection to the alternate server on port 443, in a very systematic way. I'm not sure whether this problem is specific to this skype server infrastructure (the skype client fails in a similar way). Anyway, this code path works as expected with a non-microsoft turn server (tested with coturn).