Do not check uac->request.t_active when performing DNS failover
authorMiklos Tirpak <miklos@iptel.org>
Tue, 26 Feb 2008 08:43:45 +0000 (08:43 +0000)
committerMiklos Tirpak <miklos@iptel.org>
Tue, 26 Feb 2008 08:43:45 +0000 (08:43 +0000)
upon receiving a 503 response, t_active is always 0 in this case.
Closes SER-361

modules/tm/t_reply.c

index 4c31d6a..74b4bca 100644 (file)
@@ -1817,15 +1817,12 @@ int reply_received( struct sip_msg  *p_msg )
                }
 #endif /* USE_DST_BLACKLIST */
 #ifdef USE_DNS_FAILOVER
-               /* if this is a 503 reply, the destination resolves to more ips, and
-                *  the branch is still active (no timeout), add another branch/uac.
+               /* if this is a 503 reply, and the destination resolves to more ips,
+                *  add another branch/uac.
                 *  This code is out of LOCK_REPLIES() to minimize the time the
                 *  reply lock is held (the lock won't be held while sending the
                 *   message)*/
-               if (cfg_get(core, core_cfg, use_dns_failover) && 
-                       (msg_status==503) &&
-                       uac->request.t_active
-               ) {
+               if (cfg_get(core, core_cfg, use_dns_failover) && (msg_status==503)) {
                        branch_ret=add_uac_dns_fallback(t, t->uas.request, uac, 1);
                        prev_branch=-1;
                        while((branch_ret>=0) &&(branch_ret!=prev_branch)){