Browse Source

Revert "engine: network: do not read from uninitialized sockaddr storage"

This reverts commit 4f78ec01cf.
pull/2/head
Alibek Omarov 2 years ago
parent
commit
eaf9a9283a
  1. 4
      engine/common/net_ws.c

4
engine/common/net_ws.c

@ -1451,10 +1451,10 @@ static qboolean NET_QueuePacket( netsrc_t sock, netadr_t *from, byte *data, size @@ -1451,10 +1451,10 @@ static qboolean NET_QueuePacket( netsrc_t sock, netadr_t *from, byte *data, size
addr_len = sizeof( addr );
ret = recvfrom( net_socket, buf, sizeof( buf ), 0, (struct sockaddr *)&addr, &addr_len );
if( !NET_IsSocketError( ret ))
{
NET_SockadrToNetadr( &addr, from );
if( !NET_IsSocketError( ret ))
{
if( ret < NET_MAX_FRAGMENT )
{
// Transfer data

Loading…
Cancel
Save