Ignore:
Timestamp:
Aug 22, 2008 5:46:33 PM (13 years ago)
Author:
bennylp
Message:

Ticket #598: Update to draft-ietf-behave-rfc3489bis-18 and draft-ietf-behave-turn-09, and fix other things as well. Please see the ticket for more info

File:
1 edited

Legend:

Unmodified
Added
Removed
  • pjproject/trunk/pjnath/src/pjnath/turn_sock.c

    r2177 r2234  
    464464{ 
    465465    pj_turn_sock *turn_sock; 
     466    unsigned parsed_len; 
    466467    pj_bool_t ret = PJ_TRUE; 
    467468 
     
    471472    if (status == PJ_SUCCESS && turn_sock->sess) { 
    472473        /* Report incoming packet to TURN session */ 
    473         PJ_TODO(REPORT_PARSED_LEN); 
    474         pj_turn_session_on_rx_pkt(turn_sock->sess, data,  size); 
     474        parsed_len = (unsigned)size; 
     475        pj_turn_session_on_rx_pkt(turn_sock->sess, data,  size, &parsed_len); 
     476        if (parsed_len < (unsigned)size) { 
     477            *remainder = size - parsed_len; 
     478            pj_memmove(data, ((char*)data)+parsed_len, *remainder); 
     479        } else { 
     480            *remainder = 0; 
     481        } 
    475482    } else if (status != PJ_SUCCESS &&  
    476483               turn_sock->conn_type != PJ_TURN_TP_UDP)  
Note: See TracChangeset for help on using the changeset viewer.