diff options
Diffstat (limited to 'src/sdl_udp.c')
| -rw-r--r-- | src/sdl_udp.c | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/src/sdl_udp.c b/src/sdl_udp.c index e6b669a..f4888ad 100644 --- a/src/sdl_udp.c +++ b/src/sdl_udp.c @@ -124,6 +124,10 @@ int writeSdlUdpSocket(sock_sdl_udp_t *src, sock_sdl_udp_t *dst, void *address, i assert( src != NULL ); assert( address != NULL ); +#ifdef DEBUG_LOST_PACKET + if( rand() % DEBUG_LOST_PACKET == 0 )return size; +#endif + memcpy(dst->packet->data, address, len); dst->packet->len = len; |