Ignore:
Timestamp:
Apr 8, 2008 11:33:15 PM (17 years ago)
Author:
bennylp
Message:

As per list report, changed the default response to incoming REFER from 200 to 202 as some gateways do not like this. Thanks Pedro Sanchez for the report

File:
1 edited

Legend:

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

    r1909 r1912  
    30063006 
    30073007    /* Notify callback */ 
    3008     code = PJSIP_SC_OK; 
     3008    code = PJSIP_SC_ACCEPTED; 
    30093009    if (pjsua_var.ua_cfg.cb.on_call_transfer_request) 
    30103010        (*pjsua_var.ua_cfg.cb.on_call_transfer_request)(existing_call->index, 
     
    30133013 
    30143014    if (code < 200) 
    3015         code = PJSIP_SC_OK; 
     3015        code = PJSIP_SC_ACCEPTED; 
    30163016    if (code >= 300) { 
    30173017        /* Application rejects call transfer request */ 
     
    30283028    if (no_refer_sub) { 
    30293029        /* 
    3030          * Always answer with 200. 
     3030         * Always answer with 2xx. 
    30313031         */ 
    30323032        pjsip_tx_data *tdata; 
     
    30343034        pjsip_hdr *hdr; 
    30353035 
    3036         status = pjsip_dlg_create_response(inv->dlg, rdata, 200, NULL, &tdata); 
     3036        status = pjsip_dlg_create_response(inv->dlg, rdata, code, NULL,  
     3037                                           &tdata); 
    30373038        if (status != PJ_SUCCESS) { 
    3038             pjsua_perror(THIS_FILE, "Unable to create 200 response to REFER", 
     3039            pjsua_perror(THIS_FILE, "Unable to create 2xx response to REFER", 
    30393040                         status); 
    30403041            return; 
     
    30523053                                         tdata); 
    30533054        if (status != PJ_SUCCESS) { 
    3054             pjsua_perror(THIS_FILE, "Unable to create 200 response to REFER", 
     3055            pjsua_perror(THIS_FILE, "Unable to create 2xx response to REFER", 
    30553056                         status); 
    30563057            return; 
     
    30943095        } 
    30953096 
    3096         /* Accept the REFER request, send 200 (OK). */ 
     3097        /* Accept the REFER request, send 2xx. */ 
    30973098        pjsip_xfer_accept(sub, rdata, code, &hdr_list); 
    30983099 
Note: See TracChangeset for help on using the changeset viewer.