Switch ENet errors to Nazara

This commit is contained in:
Lynix 2017-03-02 16:18:34 +01:00
parent ad8857354f
commit f2fb0f62c2
1 changed files with 15 additions and 22 deletions

View File

@ -224,9 +224,7 @@ namespace Nz
return 1; return 1;
case -1: case -1:
#ifdef ENET_DEBUG NazaraError("Error sending outgoing packets");
perror("Error sending outgoing packets");
#endif
return -1; return -1;
default: default:
@ -235,34 +233,29 @@ namespace Nz
switch (ReceiveIncomingCommands(event)) switch (ReceiveIncomingCommands(event))
{ {
case 1: case 1:
return 1; return 1;
case -1: case -1:
#ifdef ENET_DEBUG NazaraError("Error receiving incoming packets");
perror("Error receiving incoming packets"); return -1;
#endif
return -1; default:
break;
default:
break;
} }
switch (SendOutgoingCommands(event, true)) switch (SendOutgoingCommands(event, true))
{ {
case 1: case 1:
return 1; return 1;
case -1: case -1:
#ifdef ENET_DEBUG NazaraError("Error sending outgoing packets");
perror("Error sending outgoing packets");
#endif
return -1; return -1;
default: default:
break; break;
} }
if (event) if (event)