- Timestamp:
- Oct 1, 2014 6:45:02 AM (10 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
pjproject/trunk/pjsip/src/pjsip-ua/sip_100rel.c
r4713 r4936 376 376 377 377 378 /* Clear all responses in the transmission list */ 379 static void clear_all_responses(dlg_data *dd) 380 { 381 tx_data_list_t *tl; 382 383 tl = dd->uas_state->tx_data_list.next; 384 while (tl != &dd->uas_state->tx_data_list) { 385 pjsip_tx_data_dec_ref(tl->tdata); 386 tl = tl->next; 387 } 388 pj_list_init(&dd->uas_state->tx_data_list); 389 } 390 378 391 /* 379 392 * Notify 100rel module that the invite session has been disconnected. … … 389 402 /* Make sure we don't have pending transmission */ 390 403 if (dd->uas_state) { 391 pj_assert(!dd->uas_state->retransmit_timer.id); 392 pj_assert(pj_list_empty(&dd->uas_state->tx_data_list)); 404 /* Cancel the retransmit timer */ 405 if (dd->uas_state->retransmit_timer.id) { 406 pjsip_endpt_cancel_timer(dd->inv->dlg->endpt, 407 &dd->uas_state->retransmit_timer); 408 dd->uas_state->retransmit_timer.id = PJ_FALSE; 409 } 410 if (!pj_list_empty(&dd->uas_state->tx_data_list)) { 411 /* Clear all pending responses (drop 'em) */ 412 clear_all_responses(dd); 413 } 393 414 } 394 415 … … 425 446 p_method->slen = 0; 426 447 } 427 }428 429 /* Clear all responses in the transmission list */430 static void clear_all_responses(dlg_data *dd)431 {432 tx_data_list_t *tl;433 434 tl = dd->uas_state->tx_data_list.next;435 while (tl != &dd->uas_state->tx_data_list) {436 pjsip_tx_data_dec_ref(tl->tdata);437 tl = tl->next;438 }439 pj_list_init(&dd->uas_state->tx_data_list);440 448 } 441 449
Note: See TracChangeset
for help on using the changeset viewer.