mirror of
https://github.com/BeamMP/BeamMP-Launcher.git
synced 2026-04-04 14:56:24 +00:00
add more debug statements, wait for threads before shutting down
This commit is contained in:
@@ -107,8 +107,14 @@ std::string TCPRcv(SOCKET Sock) {
|
||||
|
||||
if (Ret.substr(0, 4) == "ABG:") {
|
||||
auto substr = Ret.substr(4);
|
||||
auto res = DeComp(std::span<char>(substr.data(), substr.size()));
|
||||
Ret = std::string(res.data(), res.size());
|
||||
try {
|
||||
auto res = DeComp(std::span<char>(substr.data(), substr.size()));
|
||||
Ret = std::string(res.data(), res.size());
|
||||
} catch (const std::runtime_error& err) {
|
||||
// this happens e.g. when we're out of memory, or when we get incomplete data
|
||||
error("Decompression failed");
|
||||
return "";
|
||||
}
|
||||
}
|
||||
|
||||
#ifdef DEBUG
|
||||
|
||||
Reference in New Issue
Block a user