Commit cb577e00 authored by Kai Vehmanen's avatar Kai Vehmanen
Browse files

Do not use resend when doing NAT type checking with STUN. The resends do not...

Do not use resend when doing NAT type checking with STUN. The resends do not currently include the request attribute bytes as they should do.

darcs-hash:20060506181330-7659e-f85490924913c03707321a1ebec04af5820ed43c.gz
parent 113884a8
......@@ -2260,8 +2260,11 @@ static void stun_sendto_timer_cb(su_root_magic_t *magic,
++req->sr_retry_count;
/* check if max retry count has been exceeded */
if (req->sr_retry_count >= sh->sh_max_retries) {
/* check if max retry count has been exceeded; or if
* action type is NAT type check (XXX: the request attributes
* are not passed correctly to resend function) */
if (req->sr_retry_count >= sh->sh_max_retries ||
action == stun_action_test_nattype) {
errno = ETIMEDOUT;
STUN_ERROR(errno, stun_sendto_timer_cb);
......@@ -2271,6 +2274,7 @@ static void stun_sendto_timer_cb(su_root_magic_t *magic,
/* Either the server was dead, address wrong or STUN_UDP_BLOCKED */
/* sd->sd_nattype = stun_udp_blocked; */
req->sr_state = stun_req_timeout;
/* If the action is binding request, we are done. If action was
NAT type determination, process with the state machine. */
switch (action) {
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment