Changeset 4929 for pjproject/trunk/pjsip/src/pjsua-lib/pjsua_call.c
- Timestamp:
- Sep 24, 2014 8:26:33 AM (10 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
pjproject/trunk/pjsip/src/pjsua-lib/pjsua_call.c
r4924 r4929 557 557 558 558 /* 559 * Cleanup call setting flag to avoid one time flags, such as 560 * PJSUA_CALL_UNHOLD, PJSUA_CALL_UPDATE_CONTACT, or 561 * PJSUA_CALL_NO_SDP_OFFER, to be sticky (ticket #1793). 562 */ 563 static void cleanup_call_setting_flag(pjsua_call_setting *opt) 564 { 565 opt->flag &= ~(PJSUA_CALL_UNHOLD | PJSUA_CALL_UPDATE_CONTACT | 566 PJSUA_CALL_NO_SDP_OFFER); 567 } 568 569 570 /* 559 571 * Initialize call settings based on account ID. 560 572 */ … … 580 592 pj_assert(call); 581 593 582 if (!opt) 594 if (!opt) { 595 cleanup_call_setting_flag(&call->opt); 583 596 return PJ_SUCCESS; 597 } 584 598 585 599 #if !PJMEDIA_HAS_VIDEO … … 1146 1160 /* Copy call setting from the replaced call */ 1147 1161 call->opt = replaced_call->opt; 1162 cleanup_call_setting_flag(&call->opt); 1148 1163 1149 1164 /* Notify application */ … … 2411 2426 call->opt.flag = options; 2412 2427 2413 status = pjsua_call_reinvite2(call_id, NULL, msg_data);2428 status = pjsua_call_reinvite2(call_id, &call->opt, msg_data); 2414 2429 2415 2430 on_return: … … 2525 2540 call->opt.flag = options; 2526 2541 2527 status = pjsua_call_update2(call_id, NULL, msg_data);2542 status = pjsua_call_update2(call_id, &call->opt, msg_data); 2528 2543 2529 2544 on_return: … … 3952 3967 if (pjsua_var.ua_cfg.cb.on_call_rx_offer) { 3953 3968 pjsip_status_code code = PJSIP_SC_OK; 3954 pjsua_call_setting opt = call->opt; 3969 pjsua_call_setting opt; 3970 3971 cleanup_call_setting_flag(&call->opt); 3972 opt = call->opt; 3955 3973 3956 3974 (*pjsua_var.ua_cfg.cb.on_call_rx_offer)(call->index, offer, NULL, … … 4374 4392 } 4375 4393 4394 cleanup_call_setting_flag(&existing_call->opt); 4376 4395 call_opt = existing_call->opt; 4377 4396 if (pjsua_var.ua_cfg.cb.on_call_transfer_request2) { … … 4677 4696 { 4678 4697 /* Call unhold failed */ 4679 call->opt.flag &= ~PJSUA_CALL_UNHOLD;4680 4698 call->local_hold = PJ_TRUE; 4681 4699 PJ_LOG(3,(THIS_FILE, "Error releasing hold on call %d (reason=%d)",
Note: See TracChangeset
for help on using the changeset viewer.