Changeset 4256

Show
Ignore:
Timestamp:
08/09/08 12:20:09 (6 years ago)
Author:
soohyunc
Message:

time stamp correctly added (rtp sender side's time stamp using gettimeofday)

Files:
1 modified

Legend:

Unmodified
Added
Removed
  • vic/branches/cc/rtp/session.cpp

    r4255 r4256  
    683683        xrb->end_seq = htonl(seqno_ + 1); 
    684684 
     685        // this chunk is used for ackvec 
    685686        if(xrh->xr_flags & (bt << 28) == XR_BT_1) { 
    686                 // this chunk is ackvec 
    687687                xrb->chunk = (u_int32_t *) htonl(tfwc_rcvr_getvec()); 
    688         } else if(xrh->xr_flags & (bt << 28) == XR_BT_3) { 
    689                 // this chunk is timestamp echo 
    690                 //xrb->chunk = (u_int32_t *) gettimeofday_usecs(); 
     688        }  
     689         
     690        // this chunk is used for timestamp 
     691        if(xrh->xr_flags & (bt << 28) == XR_BT_3) { 
     692                timeval tv; 
     693                ::gettimeofday(&tv, 0); 
     694                u_int32_t time = (u_int32_t) (tv.tv_sec + tv.tv_usec); 
     695                xrb->chunk = (u_int32_t *) time; 
    691696        } 
    692697