[asterisk-dev] expected hint value when multiple devices are combined (onHold)

Russell Bryant russell at digium.com
Thu May 7 20:17:49 CDT 2009


On May 7, 2009, at 4:27 PM, Philippe Lindheimer wrote:

> OnHold & Idle = Idle  (NOT WHAT ONE WOULD EXPECT)
>
> I conjecture that one would expect any state that 'raises' the level  
> of the combination above an idle state would return that state, and  
> basically the 'less available'  (busier so to speak) that the state  
> is, it would take precedence. Most of the behavior appears that way  
> with the exception that Idle is taking precedence of onHold which  
> seems very counter-intuitive.
>
> Before filing this as a "bug" I would like to get the feedback of  
> others what would be the proper value of such a combination.


I would agree that this is a bug.  I would expect that combination of  
states to result in an OnHold state.

The fix should be relatively easy.  The responsible code is in  
ast_extension_state2() of main/pbx.c in Asterisk 1.4.

In Asterisk trunk, the same logic was moved into some common code.   
Search for ast_devstate_aggregate in main/devicestate.c.

--
Russell Bryant
Digium, Inc. | Senior Software Engineer, Open Source Team Lead
445 Jan Davis Drive NW - Huntsville, AL 35806 - USA
Check us out at: www.digium.com & www.asterisk.org







More information about the asterisk-dev mailing list