diff options
author | oej <oej@f38db490-d61c-443f-a65b-d21fe96a405b> | 2006-04-04 18:24:41 +0000 |
---|---|---|
committer | oej <oej@f38db490-d61c-443f-a65b-d21fe96a405b> | 2006-04-04 18:24:41 +0000 |
commit | 36b1ad24ac7061d1d053c1cb870351d694e70f68 (patch) | |
tree | e0007f263a52d64114a8389b19d1ffea2d2145f3 /channels | |
parent | e2b336affeb69d9733c1f7e4a05328145a8ebce8 (diff) |
- Don't return AST_DEVICE_UNKNOWN to devicestate engine, since this will
cause a channel walk...
- Doxygen fixed for devicestate.c
git-svn-id: http://svn.digium.com/svn/asterisk/trunk@17365 f38db490-d61c-443f-a65b-d21fe96a405b
Diffstat (limited to 'channels')
-rw-r--r-- | channels/chan_sip.c | 14 |
1 files changed, 8 insertions, 6 deletions
diff --git a/channels/chan_sip.c b/channels/chan_sip.c index 76148cedf..0227773d7 100644 --- a/channels/chan_sip.c +++ b/channels/chan_sip.c @@ -11835,12 +11835,16 @@ static int sip_poke_peer(struct sip_peer *peer) For peers with call limit: - not registered AST_DEVICE_UNAVAILABLE - - registered, no call AST_DEVICE_NOT_INUSE - - registered, calls possible AST_DEVICE_INUSE + - registered, no call AST_DEVICE_NOT_INUSE + - registered, active calls AST_DEVICE_INUSE - registered, call limit reached AST_DEVICE_BUSY For peers without call limit: - not registered AST_DEVICE_UNAVAILABLE - - registered AST_DEVICE_UNKNOWN + - registered AST_DEVICE_NOT_INUSE + - fixed IP (!dynamic) AST_DEVICE_NOT_INUSE + + If we return AST_DEVICE_UNKNOWN, the device state engine will try to find + out a state by walking the channel list. */ static int sip_devicestate(void *data) { @@ -11873,10 +11877,8 @@ static int sip_devicestate(void *data) res = AST_DEVICE_BUSY; else if (p->call_limit && p->inUse) res = AST_DEVICE_INUSE; - else if (p->call_limit) - res = AST_DEVICE_NOT_INUSE; else - res = AST_DEVICE_UNKNOWN; + res = AST_DEVICE_NOT_INUSE; } } else { /* there is no address, it's unavailable */ |