[asterisk-bugs] [Asterisk 0011719]: [patch] GotoIfTime currently only handles the 'true' case. This patch adds proper Goto behavior for the 'false' case as well.

noreply at bugs.digium.com noreply at bugs.digium.com
Thu Jan 10 12:29:38 CST 2008


A NOTE has been added to this issue. 
====================================================================== 
http://bugs.digium.com/view.php?id=11719 
====================================================================== 
Reported By:                kshumard
Assigned To:                
====================================================================== 
Project:                    Asterisk
Issue ID:                   11719
Category:                   Applications/*
Reproducibility:            always
Severity:                   feature
Priority:                   normal
Status:                     new
Asterisk Version:           SVN 
SVN Branch (only for SVN checkouts, not tarball releases):  trunk 
SVN Revision (number only!): 97634 
Disclaimer on File?:        N/A 
Request Review:              
====================================================================== 
Date Submitted:             01-09-2008 17:06 CST
Last Modified:              01-10-2008 12:29 CST
====================================================================== 
Summary:                    [patch] GotoIfTime currently only handles the 'true'
case. This patch adds proper Goto behavior for the 'false' case as well.
Description: 
The principle of least surprise says that GotoIfTime should function like
GotoIf, and branch properly down either the 'true' or the 'false' path.
However, when (e.g.) exten => 1,1,GotoIfTime(15:00-15:02,*,*,*?true:false)
is evaluated, the current behavior is that if true the label "true:false"
is used and if false processing continues to the next priority. This patch
implements the typical GotoIf behavior, by properly handling labels for
both "true" and "false" evaluations of the current time against the
specified time. Thus, true evaluation of the condition Goto's the "true"
label, and false evaluation of the condition Goto's the "false" label.

The idea of a label "true:false" makes me shudder, but this is valid with
the current behavior of GotoIfTime.
====================================================================== 

---------------------------------------------------------------------- 
 Corydon76 - 01-10-08 12:29  
---------------------------------------------------------------------- 
kshumard:  what happens if the first application contains an argument with
a ':' character? 

Issue History 
Date Modified   Username       Field                    Change               
====================================================================== 
01-10-08 12:29  Corydon76      Note Added: 0076675                          
======================================================================




More information about the asterisk-bugs mailing list