mirror of
https://github.com/asterisk/asterisk.git
synced 2025-09-19 19:52:48 +00:00
deal with no callerid name
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@1209 65c4cc65-6c06-0410-ace0-fbb531ad65f3
This commit is contained in:
@@ -1009,7 +1009,10 @@ int setup_incoming_call(call_details_t cd)
|
|||||||
if (strlen(user->callerid))
|
if (strlen(user->callerid))
|
||||||
strncpy(p->callerid, user->callerid, sizeof(p->callerid) - 1);
|
strncpy(p->callerid, user->callerid, sizeof(p->callerid) - 1);
|
||||||
else
|
else
|
||||||
sprintf(p->callerid, "%s <%s>", p->cd.call_source_aliases, p->cd.call_source_e164);
|
if (!strlen(p->cd.call_source_aliases))
|
||||||
|
sprintf(p->callerid, "Unknown Name <%s>", p->cd.call_source_e164);
|
||||||
|
else
|
||||||
|
sprintf(p->callerid, "%s <%s>", p->cd.call_source_aliases, p->cd.call_source_e164);
|
||||||
|
|
||||||
if (strlen(p->cd.call_dest_e164)) {
|
if (strlen(p->cd.call_dest_e164)) {
|
||||||
strncpy(p->exten, cd.call_dest_e164, sizeof(p->exten)-1);
|
strncpy(p->exten, cd.call_dest_e164, sizeof(p->exten)-1);
|
||||||
|
Reference in New Issue
Block a user