aboutsummaryrefslogtreecommitdiffstats
path: root/main/pbx.c
diff options
context:
space:
mode:
authormurf <murf@f38db490-d61c-443f-a65b-d21fe96a405b>2008-11-12 19:36:16 +0000
committermurf <murf@f38db490-d61c-443f-a65b-d21fe96a405b>2008-11-12 19:36:16 +0000
commita00bf7f35fd0b8c11194cfb211c4ca069d4e4a20 (patch)
treef831f4c46f1e451420072b1f6414f1ae64f6afd7 /main/pbx.c
parent1573ed523c17c10f5834490bec0aeb22b54c9dc2 (diff)
It turns out that the 0x0XX00 codes being returned for
N, X, and Z are off by one, as per conversation with jsmith on #asterisk-dev; he was teaching a class and disconcerted that this published rule was not being followed, with patterns _NXX, _[1-8]22 and _[2-9]22... and NXX was winning, but [1-8] should have been. This change, tested on these 3 patterns now picks the proper one. However, this change may surprise users who set up dialplans based on previous behavior, which has been there for what, 2 and half years or so now. git-svn-id: http://svn.digium.com/svn/asterisk/branches/1.4@156297 f38db490-d61c-443f-a65b-d21fe96a405b
Diffstat (limited to 'main/pbx.c')
-rw-r--r--main/pbx.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/main/pbx.c b/main/pbx.c
index b9bdc9ba5..e324d0489 100644
--- a/main/pbx.c
+++ b/main/pbx.c
@@ -665,13 +665,13 @@ static int ext_cmp1(const char **p)
return 0x0000 | (c & 0xff);
case 'N': /* 2..9 */
- return 0x0700 | '2' ;
+ return 0x0800 | '2' ;
case 'X': /* 0..9 */
- return 0x0900 | '0';
+ return 0x0A00 | '0';
case 'Z': /* 1..9 */
- return 0x0800 | '1';
+ return 0x0900 | '1';
case '.': /* wildcard */
return 0x10000;