aboutsummaryrefslogtreecommitdiffstats
path: root/main/pbx.c
diff options
context:
space:
mode:
authortilghman <tilghman@f38db490-d61c-443f-a65b-d21fe96a405b>2010-01-12 20:01:02 +0000
committertilghman <tilghman@f38db490-d61c-443f-a65b-d21fe96a405b>2010-01-12 20:01:02 +0000
commit240e1c2cb45194aab25e17f952e4e85bed5beb54 (patch)
treea1d65bb5d4a7303e4790d3a421ac794e8e5524c9 /main/pbx.c
parentbc7af8f81e449f0f35d054bc83455f0d5a06a52b (diff)
Merged revisions 239571 via svnmerge from
https://origsvn.digium.com/svn/asterisk/trunk ........ r239571 | tilghman | 2010-01-12 13:58:00 -0600 (Tue, 12 Jan 2010) | 5 lines Blank callerid and NULL callerid should not compare equal. The second is the default state for matching CID in the dialplan (no matching) while the first matches one particular CallerID. This is a regression. (fixes AST-314, SWP-611) ........ git-svn-id: http://svn.digium.com/svn/asterisk/branches/1.6.2@239575 f38db490-d61c-443f-a65b-d21fe96a405b
Diffstat (limited to 'main/pbx.c')
-rw-r--r--main/pbx.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/main/pbx.c b/main/pbx.c
index bad962024..3b31c301f 100644
--- a/main/pbx.c
+++ b/main/pbx.c
@@ -7688,7 +7688,9 @@ static int ast_add_extension2_lockopt(struct ast_context *con,
p += ext_strncpy(p, extension, strlen(extension) + 1) + 1;
tmp->priority = priority;
tmp->cidmatch = p; /* but use p for assignments below */
- if (!ast_strlen_zero(callerid)) {
+
+ /* Blank callerid and NULL callerid are two SEPARATE things. Do NOT confuse the two!!! */
+ if (callerid) {
p += ext_strncpy(p, callerid, strlen(callerid) + 1) + 1;
tmp->matchcid = 1;
} else {