Changeset 501 for pjproject/trunk
- Timestamp:
- Jun 13, 2006 10:22:54 PM (18 years ago)
- Location:
- pjproject/trunk/pjmedia
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
pjproject/trunk/pjmedia/include/pjmedia/sdp_neg.h
r411 r501 393 393 const pjmedia_sdp_session **remote); 394 394 395 396 /** 397 * Determine whether remote sent answer (as opposed to offer) on the 398 * last negotiation. This function can only be called in state 399 * PJMEDIA_SDP_NEG_STATE_DONE. 400 * 401 * @param neg The SDP negotiator instance. 402 * 403 * @return Non-zero if it was remote who sent answer, 404 * otherwise zero if it was local who supplied 405 * answer. 406 */ 407 PJ_DECL(pj_bool_t) 408 pjmedia_sdp_neg_was_answer_remote(pjmedia_sdp_neg *neg); 409 410 395 411 /** 396 412 * Get the current remote SDP offer or answer. Application can only -
pjproject/trunk/pjmedia/src/pjmedia/sdp_neg.c
r280 r501 33 33 pjmedia_sdp_neg_state state; /**< Negotiator state. */ 34 34 pj_bool_t has_remote_answer; 35 pj_bool_t answer_was_remote; 35 36 36 37 pjmedia_sdp_session *initial_sdp, /**< Initial local SDP */ … … 175 176 } 176 177 178 179 PJ_DEF(pj_bool_t) 180 pjmedia_sdp_neg_was_answer_remote(pjmedia_sdp_neg *neg) 181 { 182 PJ_ASSERT_RETURN(neg, PJ_FALSE); 183 184 return neg->answer_was_remote; 185 } 186 187 177 188 PJ_DEF(pj_status_t) 178 189 pjmedia_sdp_neg_get_neg_remote( pjmedia_sdp_neg *neg, … … 275 286 /* We're ready to negotiate. */ 276 287 neg->state = PJMEDIA_SDP_NEG_STATE_WAIT_NEGO; 277 neg->has_remote_answer = 1;288 neg->has_remote_answer = PJ_TRUE; 278 289 neg->neg_remote_sdp = pjmedia_sdp_session_clone(pool, remote); 279 290 … … 918 929 neg->state = PJMEDIA_SDP_NEG_STATE_DONE; 919 930 931 /* Save state */ 932 neg->answer_was_remote = neg->has_remote_answer; 933 920 934 /* Clear temporary SDP */ 921 935 neg->neg_local_sdp = neg->neg_remote_sdp = NULL; 922 neg->has_remote_answer = 0;936 neg->has_remote_answer = PJ_FALSE; 923 937 924 938 return status;
Note: See TracChangeset
for help on using the changeset viewer.