aboutsummaryrefslogtreecommitdiffstats
path: root/channels
diff options
context:
space:
mode:
authormmichelson <mmichelson@f38db490-d61c-443f-a65b-d21fe96a405b>2008-03-24 19:20:30 +0000
committermmichelson <mmichelson@f38db490-d61c-443f-a65b-d21fe96a405b>2008-03-24 19:20:30 +0000
commit6193f6ded69fb654c6c07701a2ab07c50e3e860f (patch)
tree46842907a913a64d5022ef03ad7a4b7de7cec5fe /channels
parentf9d823404b639db5575b0e06a693ae720e4c900b (diff)
Merged revisions 110619 via svnmerge from
https://origsvn.digium.com/svn/asterisk/trunk ................ r110619 | mmichelson | 2008-03-24 14:19:37 -0500 (Mon, 24 Mar 2008) | 23 lines Merged revisions 110618 via svnmerge from https://origsvn.digium.com/svn/asterisk/branches/1.4 ........ r110618 | mmichelson | 2008-03-24 14:17:41 -0500 (Mon, 24 Mar 2008) | 15 lines This is a revert for revision 108288. The reason is that that revision was not for an actual bug fix per se, and so it really should not have been in 1.4 in the first place. Plus, people who compile with DO_CRASH are more likely to encounter a crash due to this change. While I think the usage of DO_CRASH in ast_sched_del is a bit absurd, this sort of change is beyond the scope of 1.4 and should be done instead in a developer branch based on trunk so that all scheduler functions are fixed at once. I also am reverting the change to trunk and 1.6 since they also suffer from the DO_CRASH potential. (closes issue #12272) Reported by: qq12345 ........ ................ git-svn-id: http://svn.digium.com/svn/asterisk/branches/1.6.0@110620 f38db490-d61c-443f-a65b-d21fe96a405b
Diffstat (limited to 'channels')
-rw-r--r--channels/chan_sip.c7
1 files changed, 3 insertions, 4 deletions
diff --git a/channels/chan_sip.c b/channels/chan_sip.c
index e593c514e..56efbd607 100644
--- a/channels/chan_sip.c
+++ b/channels/chan_sip.c
@@ -4201,8 +4201,7 @@ static int sip_call(struct ast_channel *ast, char *dest, int timeout)
p->invitestate = INV_CALLING;
/* Initialize auto-congest time */
- ast_sched_del(sched, p->initid);
- p->initid = ast_sched_add(sched, p->timer_b, auto_congest, dialog_ref(p));
+ AST_SCHED_REPLACE(p->initid, sched, p->timer_b, auto_congest, dialog_ref(p));
}
return res;
@@ -4271,7 +4270,7 @@ static void __sip_destroy(struct sip_pvt *p, int lockowner, int lockdialoglist)
if (p->stateid > -1)
ast_extension_state_del(p->stateid, NULL);
- ast_sched_del(sched, p->initid);
+ AST_SCHED_DEL(sched, p->initid);
AST_SCHED_DEL(sched, p->waitid);
AST_SCHED_DEL(sched, p->autokillid);
@@ -14481,7 +14480,7 @@ static void handle_response_invite(struct sip_pvt *p, int resp, char *rest, stru
/* Acknowledge sequence number - This only happens on INVITE from SIP-call */
/* Don't auto congest anymore since we've gotten something useful back */
- ast_sched_del(sched, p->initid);
+ AST_SCHED_DEL(sched, p->initid);
/* RFC3261 says we must treat every 1xx response (but not 100)
that we don't recognize as if it was 183.