Fix segfault
git-svn-id: http://svn.digium.com/svn/asterisk/trunk@4190 f38db490-d61c-443f-a65b-d21fe96a405b
This commit is contained in:
parent
fb31a3736f
commit
de772a14e6
|
@ -5417,8 +5417,8 @@ static int check_user_full(struct sip_pvt *p, struct sip_request *req, char *cmd
|
|||
strncpy(p->username, peer->username, sizeof(p->username) - 1);
|
||||
strncpy(p->authname, peer->username, sizeof(p->authname) - 1);
|
||||
}
|
||||
if (!ast_strlen_zero(user->cid_num) && !ast_strlen_zero(p->cid_num)) {
|
||||
strncpy(p->cid_num, user->cid_num, sizeof(p->cid_num) - 1);
|
||||
if (!ast_strlen_zero(peer->cid_num) && !ast_strlen_zero(p->cid_num)) {
|
||||
strncpy(p->cid_num, peer->cid_num, sizeof(p->cid_num) - 1);
|
||||
ast_shrink_phone_number(p->cid_num);
|
||||
}
|
||||
if (!ast_strlen_zero(peer->cid_name) && !ast_strlen_zero(p->cid_name))
|
||||
|
|
Reference in New Issue