mirror of
https://github.com/BeamMP/BeamMP-Launcher.git
synced 2026-06-23 13:02:25 +00:00
enforce expected recv size during event and server info tcp recv, remove unused instance of CheckBytes function
This commit is contained in:
@@ -50,17 +50,6 @@ int KillSocket(uint64_t Dead) {
|
||||
return a;
|
||||
}
|
||||
|
||||
bool CheckBytes(uint32_t Bytes) {
|
||||
if (Bytes == 0) {
|
||||
debug("(Proxy) Connection closing");
|
||||
return false;
|
||||
} else if (Bytes < 0) {
|
||||
debug("(Proxy) send failed with error: " + std::to_string(WSAGetLastError()));
|
||||
return false;
|
||||
}
|
||||
return true;
|
||||
}
|
||||
|
||||
void GameSend(std::string_view Data) {
|
||||
static std::mutex Lock;
|
||||
std::scoped_lock Guard(Lock);
|
||||
|
||||
Reference in New Issue
Block a user