Changeset 3217 for pjproject/trunk
- Timestamp:
- Jun 23, 2010 12:21:20 PM (14 years ago)
- Location:
- pjproject/trunk
- Files:
-
- 3 edited
Legend:
- Unmodified
- Added
- Removed
-
pjproject/trunk/pjmedia/include/pjmedia/sdp_neg.h
r2394 r3217 623 623 624 624 /** 625 * Cancel previously sent offer, and move negotiator state back to 626 * previous stable state (PJMEDIA_SDP_NEG_STATE_DONE). The negotiator 627 * must be in PJMEDIA_SDP_NEG_STATE_LOCAL_OFFER state. 625 * Cancel any pending offer, whether the offer is initiated by local or 626 * remote, and move negotiator state back to previous stable state 627 * (PJMEDIA_SDP_NEG_STATE_DONE). The negotiator must be in 628 * PJMEDIA_SDP_NEG_STATE_LOCAL_OFFER or PJMEDIA_SDP_NEG_STATE_REMOTE_OFFER 629 * state. 628 630 * 629 631 * @param neg The negotiator. -
pjproject/trunk/pjmedia/src/pjmedia/sdp_neg.c
r3198 r3217 1391 1391 1392 1392 /* Must be in LOCAL_OFFER state. */ 1393 PJ_ASSERT_RETURN(neg->state == PJMEDIA_SDP_NEG_STATE_LOCAL_OFFER, 1393 PJ_ASSERT_RETURN(neg->state == PJMEDIA_SDP_NEG_STATE_LOCAL_OFFER || 1394 neg->state == PJMEDIA_SDP_NEG_STATE_REMOTE_OFFER, 1394 1395 PJMEDIA_SDPNEG_EINSTATE); 1395 1396 -
pjproject/trunk/pjsip/src/pjsip-ua/sip_inv.c
r3215 r3217 2790 2790 (status=inv_negotiate_sdp(inv)) != PJ_SUCCESS) 2791 2791 { 2792 /* Negotiation has failed */ 2792 /* Negotiation has failed. If negotiator is still 2793 * stuck at non-DONE state, cancel any ongoing offer. 2794 */ 2795 neg_state = pjmedia_sdp_neg_get_state(inv->neg); 2796 if (neg_state != PJMEDIA_SDP_NEG_STATE_DONE) { 2797 pjmedia_sdp_neg_cancel_offer(inv->neg); 2798 } 2799 2793 2800 status = pjsip_dlg_create_response(inv->dlg, rdata, 2794 2801 PJSIP_SC_NOT_ACCEPTABLE_HERE, … … 2902 2909 } 2903 2910 2904 /* Otherwise if we don't get successful response, cancel 2905 * our negotiator. 2906 */ 2907 if (status != PJ_SUCCESS && 2908 pjmedia_sdp_neg_get_state(inv->neg)==PJMEDIA_SDP_NEG_STATE_LOCAL_OFFER && 2911 /* Cancel the negotiation if we don't get successful negotiation by now */ 2912 if (pjmedia_sdp_neg_get_state(inv->neg) == 2913 PJMEDIA_SDP_NEG_STATE_LOCAL_OFFER && 2909 2914 tsx_inv_data && tsx_inv_data->sdp_done == PJ_FALSE) 2910 2915 {
Note: See TracChangeset
for help on using the changeset viewer.