Ticket #4578 (closed Bugs: fixed)

Opened 3 years ago

Last modified 3 years ago

call forward hint block on state "busy"

Reported by: tomarch Assigned to:
Priority: minor Milestone: 2.9
Component: Call Forward Version: 2.8-branch
Keywords: call forward hint Cc:
Confirmation: Need testing Distro:
Backend Engine: All Distro Ver:
Backend Ver: SVN Revision (if applicable):

Description

I use the call forward toggle feature key *740 with some phone. At initial state (asterisk just reboot), hint is on "idle", but after one use of the call forward feature, the state still on "busy" even if i desactived the call forward.

I also try to use the *73 feature key (desactivate all call forward)but it's the same = state:busy

exemple of the subscription panel : *740500@ext-cf-hints : Custom:DEVCF500 State:Busy Watchers 1 *740501@ext-cf-hints : Custom:DEVCF501 State:Busy Watchers 1

Change History

10/06/10 13:19:24 changed by p_lindheimer

  • confirmation changed from Unreviewed to Need Feedback.

can you provide additional information including what version of Asterisk you are using, a trace from the log file when you press *740 after it has been forwarded and you are deactivating CF.

I just tested this on a 1.4.something system and it works fine being set to Busy when enabled and showing as Idle when disabled again with *740 (I did not try with *73 and don't recall if we enabled that to set the state though probably we did).

My only guess is that we set it to "UNKNOWN" as a state which results in the Idle state, and maybe Asterisk does not like that state anymore, but if so, the requested log trace should show some sort of complaint from Asteirsk, at least hopefully.

10/07/10 03:26:27 changed by tomarch

you'r right, the state "UNKNOWN" is the problem :

[Oct 6 12:09:49] VERBOSE[12562] pbx.c: -- Executing [sstate@app-cf-toggle:6] Set("SIP/501-0000001a", "DEVICE_STATE(Custom:DEVCF501)=UNKNOWN") in new stack [Oct 6 12:09:49] ERROR[12562] func_devstate.c: DEVICE_STATE function given invalid state value 'UNKNOWN'

i'm running asterisk 1.6.2.12

10/07/10 11:39:50 changed by p_lindheimer

  • confirmation changed from Need Feedback to Need testing.

Why don't you try changing it to NOT_INUSE and report back if that resolves the issue:

Index: functions.inc.php
===================================================================
--- functions.inc.php	(revision 10360)
+++ functions.inc.php	(working copy)
@@ -124,7 +124,7 @@
 
 	$ext->add($id, $c, 'deactivate', new ext_dbdel('CF/${fromext}')); 
 	if ($amp_conf['USEDEVSTATE']) {
-		$ext->add($id, $c, '', new ext_setvar('STATE', 'UNKNOWN'));
+		$ext->add($id, $c, '', new ext_setvar('STATE', 'NOT_INUSE'));
 		$ext->add($id, $c, '', new ext_gosub('1', 'sstate', $id));
 	}
 	if ($amp_conf['FCBEEPONLY']) {
@@ -258,7 +258,7 @@
 	$ext->add($id, $c, '', new ext_wait('1')); // $cmd,n,Wait(1)
 	$ext->add($id, $c, '', new ext_dbdel('CF/${fromext}')); 
 	if ($amp_conf['USEDEVSTATE']) {
-		$ext->add($id, $c, '', new ext_setvar('STATE', 'UNKNOWN'));
+		$ext->add($id, $c, '', new ext_setvar('STATE', 'NOT_INUSE'));
 		$ext->add($id, $c, '', new ext_gosub('1', 'sstate', $id));
 	}
 	$ext->add($id, $c, 'hook_1', new ext_playback('call-fwd-unconditional&for&extension'));
@@ -296,7 +296,7 @@
 	$ext->add($id, $c, '', new ext_setvar('fromext', '${AMPUSER}'));
 	$ext->add($id, $c, '', new ext_dbdel('CF/${fromext}')); 
 	if ($amp_conf['USEDEVSTATE']) {
-		$ext->add($id, $c, '', new ext_setvar('STATE', 'UNKNOWN'));
+		$ext->add($id, $c, '', new ext_setvar('STATE', 'NOT_INUSE'));
 		$ext->add($id, $c, '', new ext_gosub('1', 'sstate', $id));
 	}
 	if ($amp_conf['FCBEEPONLY']) {
@@ -314,7 +314,7 @@
 	$ext->add($id, $c, '', new ext_setvar('fromext', '${EXTEN:'.$clen.'}'));
 	$ext->add($id, $c, '', new ext_dbdel('CF/${fromext}')); 
 	if ($amp_conf['USEDEVSTATE']) {
-		$ext->add($id, $c, '', new ext_setvar('STATE', 'UNKNOWN'));
+		$ext->add($id, $c, '', new ext_setvar('STATE', 'NOT_INUSE'));
 		$ext->add($id, $c, '', new ext_gosub('1', 'sstate', $id));
 	}
 	if ($amp_conf['FCBEEPONLY']) {

10/08/10 08:27:22 changed by tomarch

Replace "UNKNOWN" by "NOT_INUSE" resolve the issue, state come back to "idle".

10/22/10 17:54:49 changed by p_lindheimer

  • status changed from new to closed.
  • resolution set to fixed.

(In [10432]) fixes #4578 use NOT_INUSE in place of UNKNOWN

10/22/10 17:57:24 changed by p_lindheimer

(In [10433]) Merged revisions 10432 via svnmerge from http://svn.freepbx.org/modules/branches/2.8

........

r10432 | p_lindheimer | 2010-10-22 14:54:49 -0700 (Fri, 22 Oct 2010) | 1 line

fixes #4578 use NOT_INUSE in place of UNKNOWN

........

10/22/10 18:12:51 changed by p_lindheimer

(In [10440]) Merged revisions 10417,10419,10421-10422,10424-10439 via svnmerge from http://svn.freepbx.org/modules/branches/2.8 ................

r10432 | p_lindheimer | 2010-10-22 14:54:49 -0700 (Fri, 22 Oct 2010) | 1 line

fixes #4578 use NOT_INUSE in place of UNKNOWN ........

r10430 | p_lindheimer | 2010-10-22 14:50:43 -0700 (Fri, 22 Oct 2010) | 1 line

fix utility tool

........

................

r10438 | p_lindheimer | 2010-10-22 15:02:30 -0700 (Fri, 22 Oct 2010) | 1 line

no more pl version

................