Fix segfault
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@4190 65c4cc65-6c06-0410-ace0-fbb531ad65f3
This commit is contained in:
parent
0a2fff51c7
commit
1fd3b9976a
|
@ -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))
|
||||
|
|
Loading…
Reference in New Issue