Summary: | ASTERISK-02819: [patch] leavewhenempty doens't work | ||
Reporter: | scotti (scotti) | Labels: | |
Date Opened: | 2004-11-15 16:06:24.000-0600 | Date Closed: | 2008-01-15 15:13:53.000-0600 |
Priority: | Minor | Regression? | No |
Status: | Closed/Complete | Components: | Applications/app_queue |
Versions: | Frequency of Occurrence | ||
Related Issues: | |||
Environment: | Attachments: | ||
Description: | has_no_members doens't work correctly member->status return 5 which is not an AST_CAUSE_ for a non-logged in member which causes the function to return that agents are logged in. ****** ADDITIONAL INFORMATION ****** Added a case for 5 and it seems to work fine now. static int has_no_members(struct ast_call_queue *q) { struct member *member; int empty = 1; member = q->members; while(empty && member) { switch(member->status) { case AST_CAUSE_NOSUCHDRIVER: case AST_CAUSE_UNREGISTERED: case 5: /* Not logged on, etc */ break; default: /* Not empty */ empty = 0; } member = member->next; } return empty; } | ||
Comments: | By: triona (triona) 2004-11-15 18:35:53.000-0600 description has a fix for bug, can someone else confirm this works? By: Mark Spencer (markster) 2004-11-15 20:23:56.000-0600 Fixed in CVS, sorry about that. By: Digium Subversion (svnbot) 2008-01-15 15:13:53.000-0600 Repository: asterisk Revision: 4259 U trunk/apps/app_queue.c ------------------------------------------------------------------------ r4259 | markster | 2008-01-15 15:13:53 -0600 (Tue, 15 Jan 2008) | 2 lines Update has_no_members to know about device status codes (bug ASTERISK-2819) ------------------------------------------------------------------------ http://svn.digium.com/view/asterisk?view=rev&revision=4259 |