Commit 684a3cb1 authored by Simon Morlat's avatar Simon Morlat

fix bug in netsim

parent c1a6a0ee
......@@ -407,12 +407,12 @@ static void rtp_session_schedule_outbound_network_simulator(RtpSession *session,
if (packet_time.tv_sec<=current.tv_sec && packet_time.tv_nsec<=current.tv_nsec){
else if (om->timestamp.tv_sec==0 && om->timestamp.tv_usec==0){
todrop=om; /*simulate a packet loss*/
}else if (packet_time.tv_sec<=current.tv_sec && packet_time.tv_nsec<=current.tv_nsec){
is_rtp_packet=om->reserved1; /*it was set by _rtp_session_sendto()*/
_ortp_sendto(is_rtp_packet ? session-> : session->, om, 0, (struct sockaddr*)&om->net_addr, om->net_addrlen);
}else if (om->timestamp.tv_sec==0 && om->timestamp.tv_usec==0){
todrop=om; /*simulate a packet loss*/
}else {
/*no packet is to be sent yet; set the time at which we want to be called*/
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment