diff options
author | mmichelson <mmichelson@f38db490-d61c-443f-a65b-d21fe96a405b> | 2008-08-18 20:05:09 +0000 |
---|---|---|
committer | mmichelson <mmichelson@f38db490-d61c-443f-a65b-d21fe96a405b> | 2008-08-18 20:05:09 +0000 |
commit | 1da3b5dbc328b28ab0b95e16f54b07916b32067d (patch) | |
tree | 49ede3a2e4400f9fd1b24e2cc9d3b3befc65eaf7 /apps/app_queue.c | |
parent | 1f4693ef52d9f4b914290c763d71ae117d0fc0fb (diff) |
Merged revisions 138687 via svnmerge from
https://origsvn.digium.com/svn/asterisk/trunk
................
r138687 | mmichelson | 2008-08-18 15:04:10 -0500 (Mon, 18 Aug 2008) | 18 lines
Merged revisions 138685 via svnmerge from
https://origsvn.digium.com/svn/asterisk/branches/1.4
........
r138685 | mmichelson | 2008-08-18 15:01:14 -0500 (Mon, 18 Aug 2008) | 10 lines
Change the inequalities used in app_queue with regards
to timeouts from being strict to non-strict for more
accuracy.
(closes issue #13239)
Reported by: atis
Patches:
app_queue_timeouts_v2.patch uploaded by atis (license 242)
........
................
git-svn-id: http://svn.digium.com/svn/asterisk/branches/1.6.0@138688 f38db490-d61c-443f-a65b-d21fe96a405b
Diffstat (limited to 'apps/app_queue.c')
-rw-r--r-- | apps/app_queue.c | 18 |
1 files changed, 9 insertions, 9 deletions
diff --git a/apps/app_queue.c b/apps/app_queue.c index 0c37adb0f..082e40f0d 100644 --- a/apps/app_queue.c +++ b/apps/app_queue.c @@ -2810,7 +2810,7 @@ static int wait_our_turn(struct queue_ent *qe, int ringing, enum queue_result *r break; /* If we have timed out, break out */ - if (qe->expire && (time(NULL) > qe->expire)) { + if (qe->expire && (time(NULL) >= qe->expire)) { *reason = QUEUE_TIMEOUT; break; } @@ -2845,7 +2845,7 @@ static int wait_our_turn(struct queue_ent *qe, int ringing, enum queue_result *r break; /* If we have timed out, break out */ - if (qe->expire && (time(NULL) > qe->expire)) { + if (qe->expire && (time(NULL) >= qe->expire)) { *reason = QUEUE_TIMEOUT; break; } @@ -2856,12 +2856,12 @@ static int wait_our_turn(struct queue_ent *qe, int ringing, enum queue_result *r break; /* see if we need to move to the next penalty level for this queue */ - while (qe->pr && ((time(NULL) - qe->start) > qe->pr->time)) { + while (qe->pr && ((time(NULL) - qe->start) >= qe->pr->time)) { update_qe_rule(qe); } /* If we have timed out, break out */ - if (qe->expire && (time(NULL) > qe->expire)) { + if (qe->expire && (time(NULL) >= qe->expire)) { *reason = QUEUE_TIMEOUT; break; } @@ -2875,7 +2875,7 @@ static int wait_our_turn(struct queue_ent *qe, int ringing, enum queue_result *r } /* If we have timed out, break out */ - if (qe->expire && (time(NULL) > qe->expire)) { + if (qe->expire && (time(NULL) >= qe->expire)) { *reason = QUEUE_TIMEOUT; break; } @@ -3200,7 +3200,7 @@ static int try_calling(struct queue_ent *qe, const char *options, char *announce * This should be extremely rare. queue_exec will take care * of removing the caller and reporting the timeout as the reason. */ - if (qe->expire && now > qe->expire) { + if (qe->expire && now >= qe->expire) { res = 0; goto out; } @@ -4637,7 +4637,7 @@ check_turns: enum queue_member_status stat; /* Leave if we have exceeded our queuetimeout */ - if (qe.expire && (time(NULL) > qe.expire)) { + if (qe.expire && (time(NULL) >= qe.expire)) { record_abandoned(&qe); reason = QUEUE_TIMEOUT; res = 0; @@ -4660,7 +4660,7 @@ check_turns: goto stop; /* Leave if we have exceeded our queuetimeout */ - if (qe.expire && (time(NULL) > qe.expire)) { + if (qe.expire && (time(NULL) >= qe.expire)) { record_abandoned(&qe); reason = QUEUE_TIMEOUT; res = 0; @@ -4716,7 +4716,7 @@ check_turns: } /* Leave if we have exceeded our queuetimeout */ - if (qe.expire && (time(NULL) > qe.expire)) { + if (qe.expire && (time(NULL) >= qe.expire)) { record_abandoned(&qe); reason = QUEUE_TIMEOUT; res = 0; |