aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorrmudgett <rmudgett@f38db490-d61c-443f-a65b-d21fe96a405b>2010-05-20 23:23:21 +0000
committerrmudgett <rmudgett@f38db490-d61c-443f-a65b-d21fe96a405b>2010-05-20 23:23:21 +0000
commit64bef544bb63a3c6049043012d7ef0a798226ad6 (patch)
tree9959dd058eb30e09ca17cb2fcd727a2f6fedf263
parente5c559bcfb1e1e0359dfe35c2e04455cc187a4d7 (diff)
ast_callerid_parse() had a path that left name uninitialized.
Several callers of ast_callerid_parse() do not initialize the name parameter before calling thus there is the potential to use an uninitialized pointer. git-svn-id: http://svn.digium.com/svn/asterisk/branches/1.4@264820 f38db490-d61c-443f-a65b-d21fe96a405b
-rw-r--r--main/callerid.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/main/callerid.c b/main/callerid.c
index edc00a5e5..e08d96b4c 100644
--- a/main/callerid.c
+++ b/main/callerid.c
@@ -985,6 +985,8 @@ int ast_callerid_parse(char *instr, char **name, char **location)
*ns = '\0';
*name = ns + 1;
ast_trim_blanks(*name);
+ } else {
+ *name = NULL;
}
} else { /* no quotes, trim off leading and trailing spaces */
*name = ast_skip_blanks(instr);