From 03be36ecdab90b8c172126134e266afd3be8f74e Mon Sep 17 00:00:00 2001 From: Marc-Eric Martel Date: Sat, 28 Oct 2023 14:16:39 -0400 Subject: [PATCH] J'ai pu de messages de warning quand je build le client --- SQCSim-common/netprotocol.cpp | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/SQCSim-common/netprotocol.cpp b/SQCSim-common/netprotocol.cpp index ca2f6be..b6f0214 100644 --- a/SQCSim-common/netprotocol.cpp +++ b/SQCSim-common/netprotocol.cpp @@ -806,10 +806,10 @@ std::vector netprot::recvPacks(SOCKET sock, Buffer* buf) { int len = 0, end = 0; bool pck_received = false; char* cursor = nullptr; - + while (true) { while (!pck_received) { - int bytes = recv(sock, &buf->ptr[len], buf->len - len, NULL); + int bytes = recv(sock, &buf->ptr[len], buf->len - len, 0); if (bytes < 0) // si recv() retourne -1; ça veut dire qu'il y a plus rien a lire. return lsPck; len += bytes; @@ -930,4 +930,4 @@ void netprot::sendPackTo(SOCKET sock, Packet* pack, char** buf, default: return; } -} \ No newline at end of file +}