27 | | The issue is caused by ticket #1962 which directly returns without setting any error status after failure, to prevent double destruction. However, setting a final error status is also not desirable since if IPv4 fails, we still need to try IPv6 resolution. |
| 27 | The issue is caused when DNS resolution (pj_dns_srv_resolve() ) in pj_stun_sock_start() returns synchronously and the DNS resolution callback has been called. However, there is currently no mechanism to propagate the error from inside the callback to stun_sock, thus pj_stun_sock_start() will always return PJ_SUCCESS. This causes pjsua STUN server resolution to continue waiting until it times out. |
| 28 | |
| 29 | (Note that this issue first appears because of ticket #1962, which directly returns without setting any error status after synchronous failure, to prevent double destruction.) |