Changeset 3753 for pjproject/trunk/pjsip/src/pjsip-ua/sip_inv.c
- Timestamp:
- Sep 18, 2011 2:59:56 PM (13 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
pjproject/trunk/pjsip/src/pjsip-ua/sip_inv.c
r3553 r3753 1917 1917 PJ_ASSERT_RETURN(inv->invite_tsx, PJ_EBUG); 1918 1918 1919 pj_log_push_indent(); 1920 1919 1921 pjsip_dlg_inc_lock(inv->dlg); 1920 1922 … … 1964 1966 on_return: 1965 1967 pjsip_dlg_dec_lock(inv->dlg); 1968 pj_log_pop_indent(); 1966 1969 return status; 1967 1970 } … … 1990 1993 PJ_ASSERT_RETURN(inv->last_answer, PJ_EINVALIDOP); 1991 1994 1995 pj_log_push_indent(); 1996 1992 1997 pjsip_dlg_inc_lock(inv->dlg); 1993 1998 … … 2017 2022 on_return: 2018 2023 pjsip_dlg_dec_lock(inv->dlg); 2024 pj_log_pop_indent(); 2019 2025 return status; 2020 2026 } … … 2052 2058 /* Verify arguments. */ 2053 2059 PJ_ASSERT_RETURN(inv && p_tdata, PJ_EINVAL); 2060 2061 pj_log_push_indent(); 2054 2062 2055 2063 /* Set cause code. */ … … 2082 2090 PJ_LOG(4, (inv->obj_name, "Delaying CANCEL since no " 2083 2091 "provisional response is received yet")); 2092 pj_log_pop_indent(); 2084 2093 return PJ_SUCCESS; 2085 2094 } … … 2093 2102 inv->invite_tsx->last_tx, 2094 2103 &tdata); 2095 if (status != PJ_SUCCESS) 2104 if (status != PJ_SUCCESS) { 2105 pj_log_pop_indent(); 2096 2106 return status; 2107 } 2097 2108 2098 2109 /* Set timeout for the INVITE transaction, in case UAS is not … … 2126 2137 case PJSIP_INV_STATE_DISCONNECTED: 2127 2138 /* No need to do anything. */ 2139 pj_log_pop_indent(); 2128 2140 return PJSIP_ESESSIONTERMINATED; 2129 2141 2130 2142 default: 2131 2143 pj_assert("!Invalid operation!"); 2144 pj_log_pop_indent(); 2132 2145 return PJ_EINVALIDOP; 2133 2146 } 2134 2147 2135 if (status != PJ_SUCCESS) 2148 if (status != PJ_SUCCESS) { 2149 pj_log_pop_indent(); 2136 2150 return status; 2151 } 2137 2152 2138 2153 … … 2142 2157 *p_tdata = tdata; 2143 2158 2159 pj_log_pop_indent(); 2144 2160 return PJ_SUCCESS; 2145 2161 } … … 2364 2380 return PJ_EINVALIDOP; 2365 2381 2382 pj_log_push_indent(); 2366 2383 2367 2384 pjsip_dlg_inc_lock(inv->dlg); … … 2434 2451 on_return: 2435 2452 pjsip_dlg_dec_lock(inv->dlg); 2453 pj_log_pop_indent(); 2436 2454 return status; 2437 2455 } … … 2460 2478 PJ_ASSERT_RETURN(inv->state < PJSIP_INV_STATE_DISCONNECTED, 2461 2479 PJ_EINVALIDOP); 2480 2481 pj_log_push_indent(); 2462 2482 2463 2483 /* Lock dialog. */ … … 2523 2543 *p_tdata = tdata; 2524 2544 2545 pj_log_pop_indent(); 2525 2546 return PJ_SUCCESS; 2526 2547 … … 2532 2553 pjsip_dlg_dec_lock(inv->dlg); 2533 2554 2555 pj_log_pop_indent(); 2534 2556 return status; 2535 2557 } … … 2594 2616 PJ_ASSERT_RETURN(inv && tdata, PJ_EINVAL); 2595 2617 2618 pj_log_push_indent(); 2619 2596 2620 PJ_LOG(5,(inv->obj_name, "Sending %s", 2597 2621 pjsip_tx_data_get_info(tdata))); … … 2608 2632 pjsip_tx_data_dec_ref(tdata); 2609 2633 pjsip_dlg_dec_lock(inv->dlg); 2610 return PJ_EINVALIDOP; 2634 status = PJ_EINVALIDOP; 2635 goto on_error; 2611 2636 } 2612 2637 … … 2619 2644 status = pjsip_dlg_send_request(inv->dlg, tdata, mod_inv.mod.id, 2620 2645 tsx_inv_data); 2621 if (status != PJ_SUCCESS) 2622 return status; 2646 if (status != PJ_SUCCESS) { 2647 goto on_error; 2648 } 2623 2649 2624 2650 } else { … … 2639 2665 } 2640 2666 2641 if (status != PJ_SUCCESS) 2642 return status; 2643 } 2644 2645 /* Done (?) */ 2667 if (status != PJ_SUCCESS) { 2668 goto on_error; 2669 } 2670 } 2671 2672 /* Done */ 2673 pj_log_pop_indent(); 2646 2674 return PJ_SUCCESS; 2675 2676 on_error: 2677 pj_log_pop_indent(); 2678 return status; 2647 2679 } 2648 2680
Note: See TracChangeset
for help on using the changeset viewer.