MayamaTakeshi / sip-lab

A node module that helps to write SIP functional tests
3 stars 2 forks source link

Debug occasional crash when running samples/sip_cancel.js #21

Closed MayamaTakeshi closed 2 years ago

MayamaTakeshi commented 2 years ago

The script samples/sip_cancel.js frequently crashes with:

pjproject/src/pjsip/pjsip/sip_transaction.c:3267: pj_status_t tsx_on_state_completed_uas(pjsip_transaction *, pjsip_event *): Assertion `event->type == PJSIP_EVENT_TX_MSG && event->body.tx_msg.tdata == tsx->last_tx' failed.
MayamaTakeshi commented 2 years ago

Crash was solved by updating pjproject to latest commit 797088ed (see https://github.com/pjsip/pjproject/issues/2665) and checking if we have a valid pointer to a sip_msg.

Also, we noticed with the new commit, pjproject doesn't automatically reply with '487 Request Terminated' to CANCEL requests anymore so we updated samples/sip_cancel.js accordingly.