Skip to content

Commit

Permalink
tm: use relayed_code for active type check in TMCB RESPONSE OUT
Browse files Browse the repository at this point in the history
- relayed_msg can be a fake reply and accessing the status field causes
  a crash (issue introduced by previous patch)
  • Loading branch information
miconda committed Nov 10, 2017
1 parent 313265a commit 2a80ed8
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/modules/tm/t_reply.c
Expand Up @@ -1978,7 +1978,7 @@ enum rps relay_reply( struct cell *t, struct sip_msg *p_msg, int branch,
if (unlikely(!totag_retr
&& has_tran_tmcbs(t, TMCB_RESPONSE_OUT))){
LOCK_REPLIES( t );
if(relayed_msg->REPLY_STATUS==uas_rb->activ_type) {
if(relayed_code==uas_rb->activ_type) {
run_trans_callbacks_with_buf( TMCB_RESPONSE_OUT, uas_rb,
t->uas.request, relayed_msg, TMCB_NONE_F);
}
Expand Down

0 comments on commit 2a80ed8

Please sign in to comment.