aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorfile <file@f38db490-d61c-443f-a65b-d21fe96a405b>2009-03-04 19:25:59 +0000
committerfile <file@f38db490-d61c-443f-a65b-d21fe96a405b>2009-03-04 19:25:59 +0000
commitb18379b2a609304e8dafeb560275415a965dcef5 (patch)
tree6a384205b26ad025af3112e3a2fe92bc053bca26
parent5869046f68a3ac0af1c5bd9c24bd9ade2ee316b5 (diff)
Merged revisions 180195 via svnmerge from
https://origsvn.digium.com/svn/asterisk/trunk ................ r180195 | file | 2009-03-04 15:24:59 -0400 (Wed, 04 Mar 2009) | 11 lines Merged revisions 180194 via svnmerge from https://origsvn.digium.com/svn/asterisk/branches/1.4 ........ r180194 | file | 2009-03-04 15:22:50 -0400 (Wed, 04 Mar 2009) | 4 lines Look for the number in a callerid string starting from the end. This way a value using <> can exist in the name portion. (issue #AST-194) ........ ................ git-svn-id: http://svn.digium.com/svn/asterisk/branches/1.6.0@180196 f38db490-d61c-443f-a65b-d21fe96a405b
-rw-r--r--main/callerid.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/main/callerid.c b/main/callerid.c
index f2ca3cc4e..c92f84ba4 100644
--- a/main/callerid.c
+++ b/main/callerid.c
@@ -983,7 +983,7 @@ int ast_callerid_parse(char *instr, char **name, char **location)
char *ns, *ne, *ls, *le;
/* Try "name" <location> format or name <location> format */
- if ((ls = strchr(instr, '<')) && (le = strchr(ls, '>'))) {
+ if ((ls = strrchr(instr, '<')) && (le = strrchr(ls, '>'))) {
*ls = *le = '\0'; /* location found, trim off the brackets */
*location = ls + 1; /* and this is the result */
if ((ns = strchr(instr, '"')) && (ne = strchr(ns + 1, '"'))) {