[asterisk-bugs] [Asterisk 0017145]: AEL warning when using Return() application is misleading

Asterisk Bug Tracker noreply at bugs.digium.com
Wed Apr 7 01:00:33 CDT 2010


The following issue has been SUBMITTED. 
====================================================================== 
https://issues.asterisk.org/view.php?id=17145 
====================================================================== 
Reported By:                okrief
Assigned To:                
====================================================================== 
Project:                    Asterisk
Issue ID:                   17145
Category:                   Utilities/aelparse
Reproducibility:            always
Severity:                   minor
Priority:                   normal
Status:                     new
Asterisk Version:           1.6.1.18 
JIRA:                        
Regression:                 No 
Reviewboard Link:            
SVN Branch (only for SVN checkouts, not tarball releases): N/A 
SVN Revision (number only!):  
Request Review:              
====================================================================== 
Date Submitted:             2010-04-07 01:00 CDT
Last Modified:              2010-04-07 01:00 CDT
====================================================================== 
Summary:                    AEL warning when using Return() application is
misleading
Description: 
When using Return() app in AEL script, CLI output includes:
[Apr  2 14:11:12] WARNING[2217]: ael/pval.c:2522 check_pval_item: Warning:
file /etc/asterisk/extensions.ael, line 660-660: application call to Return
affects flow of control, and needs to be re-written using AEL if, while,
goto, etc. keywords instead!
To my knowledge, using return keyword instead is not a desirable
replacement as you cannot add a value to it.

In UPGRADE-1.6.txt, you can read:
AEL:

* Macros are now implemented underneath with the Gosub() application.
  Heaven Help You if you wrote code depending on any aspect of this!
  Previous to 1.6, macros were implemented with the Macro() app, which
  provided a nice feature of auto-returning. The compiler will do its
  best to insert a Return() app call at the end of your macro if you did
  not include it, but really, you should make sure that all execution
  paths within your macros end in "return;".

My understanding of all this is that AEL warning is misleading as using
Return() is not deprecated. 
====================================================================== 

Issue History 
Date Modified    Username       Field                    Change               
====================================================================== 
2010-04-07 01:00 okrief         New Issue                                    
2010-04-07 01:00 okrief         Asterisk Version          => 1.6.1.18        
2010-04-07 01:00 okrief         Regression                => No              
2010-04-07 01:00 okrief         SVN Branch (only for SVN checkouts, not tarball
releases) => N/A             
======================================================================




More information about the asterisk-bugs mailing list