Fix recv return type and better download error handling

This commit is contained in:
Tixx
2025-03-28 23:47:59 +01:00
parent ad7177bec8
commit 472e2d16b6
4 changed files with 12 additions and 6 deletions

View File

@@ -81,7 +81,8 @@ std::string TCPRcv(SOCKET Sock) {
UUl("Invalid Socket");
return "";
}
int32_t Header, Temp;
int32_t Header;
int Temp;
std::vector<char> Data(sizeof(Header));
Temp = recv(Sock, Data.data(), sizeof(Header), MSG_WAITALL);
if (!CheckBytes(Temp)) {