Ignore:
Timestamp:
Jun 20, 2012 10:39:05 AM (12 years ago)
Author:
ming
Message:

Fixed #1537: Via rewrite: putting the right IP address in Via sent-by for outgoing requests

File:
1 edited

Legend:

Unmodified
Added
Removed
  • pjproject/trunk/pjsip/src/pjsua-lib/pjsua_im.c

    r3553 r4173  
    602602    pjsua_set_msg_route_set(tdata, &acc->route_set); 
    603603 
     604    /* If via_addr is set, use this address for the Via header. */ 
     605    if (acc->cfg.allow_via_rewrite && acc->via_addr.host.slen > 0) { 
     606        tdata->via_addr = acc->via_addr; 
     607        tdata->via_tp = acc->via_tp; 
     608    } 
     609 
    604610    /* Send request (statefully) */ 
    605611    status = pjsip_endpt_send_request( pjsua_var.endpt, tdata, -1,  
     
    685691    pjsua_set_msg_route_set(tdata, &acc->route_set); 
    686692 
     693    /* If via_addr is set, use this address for the Via header. */ 
     694    if (acc->cfg.allow_via_rewrite && acc->via_addr.host.slen > 0) { 
     695        tdata->via_addr = acc->via_addr; 
     696        tdata->via_tp = acc->via_tp; 
     697    } 
     698 
    687699    /* Create data to reauthenticate */ 
    688700    im_data = PJ_POOL_ZALLOC_T(tdata->pool, pjsua_im_data); 
Note: See TracChangeset for help on using the changeset viewer.