Changeset 3954


Ignore:
Timestamp:
Feb 18, 2012 2:12:22 AM (13 years ago)
Author:
bennylp
Message:

Fixed #1452: Wrong call media state is reported if hold request is challenged with authentication (thanks Bogdan Krakowski for the fix)

Location:
pjproject/branches/1.x/pjsip
Files:
3 edited

Legend:

Unmodified
Added
Removed
  • pjproject/branches/1.x/pjsip/include/pjsip/sip_transport.h

    r3553 r3954  
    573573     */ 
    574574    pjsip_tpselector        tp_sel; 
     575 
     576    /** 
     577     * Special flag to indicate that this transmit data is a request that has 
     578     * been updated with proper authentication response and is ready to be 
     579     * sent for retry. 
     580     */ 
     581    pj_bool_t               auth_retry; 
    575582 
    576583    /** 
  • pjproject/branches/1.x/pjsip/src/pjsip/sip_auth_client.c

    r3871 r3954  
    11041104 
    11051105    tdata = old_request; 
    1106      
     1106    tdata->auth_retry = PJ_FALSE; 
     1107 
    11071108    /* 
    11081109     * Respond to each authentication challenge. 
     
    11751176    pjsip_tx_data_invalidate_msg(tdata); 
    11761177 
     1178    /* Retrying.. */ 
     1179    tdata->auth_retry = PJ_TRUE; 
     1180 
    11771181    /* Increment reference counter. */ 
    11781182    pjsip_tx_data_add_ref(tdata); 
  • pjproject/branches/1.x/pjsip/src/pjsua-lib/pjsua_call.c

    r3771 r3954  
    43274327    } 
    43284328 
     4329    /* https://trac.pjsip.org/repos/ticket/1452: 
     4330     *    If a request is retried due to 401/407 challenge, don't process the 
     4331     *    transaction first but wait until we've retried it. 
     4332     */ 
     4333    if (tsx->role == PJSIP_ROLE_UAC && 
     4334        (tsx->status_code==401 || tsx->status_code==407) && 
     4335        tsx->last_tx && tsx->last_tx->auth_retry) 
     4336    { 
     4337        PJSUA_UNLOCK(); 
     4338        return; 
     4339    } 
     4340 
    43294341    /* Notify application callback first */ 
    43304342    if (pjsua_var.ua_cfg.cb.on_call_tsx_state) { 
Note: See TracChangeset for help on using the changeset viewer.