aboutsummaryrefslogtreecommitdiffstats
path: root/channels
diff options
context:
space:
mode:
authorfile <file@f38db490-d61c-443f-a65b-d21fe96a405b>2008-01-28 19:04:53 +0000
committerfile <file@f38db490-d61c-443f-a65b-d21fe96a405b>2008-01-28 19:04:53 +0000
commit554972df7ce2d9039fa1be490eba6c1362b88382 (patch)
tree95ffb97e70e27012e2e66cdc5f0997717665ba40 /channels
parent7a7308449b5146348e96bdb45e48b08ea69a97ad (diff)
Fix up two scheduling issues. In one instance a scheduled item was not deleted when it should have been and in the other it was scheduled again when it shouldn't have been.
git-svn-id: http://svn.digium.com/svn/asterisk/trunk@100632 f38db490-d61c-443f-a65b-d21fe96a405b
Diffstat (limited to 'channels')
-rw-r--r--channels/chan_sip.c3
1 files changed, 1 insertions, 2 deletions
diff --git a/channels/chan_sip.c b/channels/chan_sip.c
index b13759e21..2cb8988b7 100644
--- a/channels/chan_sip.c
+++ b/channels/chan_sip.c
@@ -2820,8 +2820,6 @@ static enum sip_result __sip_reliable_xmit(struct sip_pvt *p, int seqno, int res
append_history(pkt->owner, "XmitErr", "%s", pkt->is_fatal ? "(Critical)" : "(Non-critical)");
return AST_FAILURE;
} else {
- /* Schedule retransmission */
- pkt->retransid = ast_sched_add_variable(sched, siptimer_a, retrans_pkt, pkt, 1);
return AST_SUCCESS;
}
}
@@ -2946,6 +2944,7 @@ static void __sip_ack(struct sip_pvt *p, int seqno, int resp, int sipmethod)
if (sipdebug)
ast_debug(4, "** SIP TIMER: Cancelling retransmit of packet (reply received) Retransid #%d\n", cur->retransid);
}
+ AST_SCHED_DEL(sched, cur->retransid);
UNLINK(cur, p->packets, prev);
dialog_unref(cur->owner);
ast_free(cur);