version 1.4 | | version 1.5 |
---|
| | |
#include "ipx_drv.h" | | #include "ipx_drv.h" |
#include "types.h" | | #include "types.h" |
#include "mono.h" | | #include "mono.h" |
| | #include "netstats.h" |
//#include "multi.h" | | //#include "multi.h" |
} | | } |
| | |
| | |
addr.dump(); | | addr.dump(); |
puts(")."); | | puts(")."); |
#endif | | #endif |
| | net_stats_sent(len); |
return sendto(mysock,buf,len,0,(struct sockaddr *)&toaddr,sizeof(toaddr)); | | return sendto(mysock,buf,len,0,(struct sockaddr *)&toaddr,sizeof(toaddr)); |
} | | } |
| | |
| | |
msg("setsockopt(IPTOS_LOWDELAY) failed: %m"); | | msg("setsockopt(IPTOS_LOWDELAY) failed: %m"); |
} | | } |
#endif | | #endif |
| | net_stats_init(28); // IP + UDP header overhead = 28 bytes. |
| | |
return 0; | | return 0; |
} | | } |
| | |
return -1; | | return -1; |
| | |
if (fromaddr.sin_family!=AF_INET) return -1; | | if (fromaddr.sin_family!=AF_INET) return -1; |
| | |
| | net_stats_recv(size); |
| | |
#ifdef UDPDEBUG | | #ifdef UDPDEBUG |
printf(MSGHDR "recvfrom((%d-2=%d),",size,size-2); | | printf(MSGHDR "recvfrom((%d-2=%d),",size,size-2); |