[asterisk-commits] elguero: branch 10 r376143 - in /branches/10: ./ main/pbx.c

SVN commits to the Asterisk project asterisk-commits at lists.digium.com
Mon Nov 12 14:15:31 CST 2012


Author: elguero
Date: Mon Nov 12 14:15:27 2012
New Revision: 376143

URL: http://svnview.digium.com/svn/asterisk?view=rev&rev=376143
Log:
Fix Dynamic Hints Variable Substition - Underscore Problem

When adding a dynamic hint, if an extension contains an underscore no variable
subsitution is being performed.

This patch changes from checking if the extension contains an underscore to
checking if the extension begins with an underscore.

(closes issue ASTERISK-20639)
Reported by: Steven T. Wheeler
Tested by: Steven T. Wheeler, Michael L. Young
Patches:
  asterisk-20639-dynamic-hint-underscore.diff 
                                     uploaded by Michael L. Young (license 5026)

Review: https://reviewboard.asterisk.org/r/2188/
........

Merged revisions 376142 from http://svn.asterisk.org/svn/asterisk/branches/1.8

Modified:
    branches/10/   (props changed)
    branches/10/main/pbx.c

Propchange: branches/10/
------------------------------------------------------------------------------
Binary property 'branch-1.8-merged' - no diff available.

Modified: branches/10/main/pbx.c
URL: http://svnview.digium.com/svn/asterisk/branches/10/main/pbx.c?view=diff&rev=376143&r1=376142&r2=376143
==============================================================================
--- branches/10/main/pbx.c (original)
+++ branches/10/main/pbx.c Mon Nov 12 14:15:27 2012
@@ -8681,7 +8681,7 @@
 	}
 
 	/* If we are adding a hint evalulate in variables and global variables */
-	if (priority == PRIORITY_HINT && strstr(application, "${") && !strstr(extension, "_")) {
+	if (priority == PRIORITY_HINT && strstr(application, "${") && extension[0] != '_') {
 		struct ast_channel *c = ast_dummy_channel_alloc();
 
 		if (c) {




More information about the asterisk-commits mailing list