1
0
mirror of https://github.com/vcmi/vcmi.git synced 2025-04-25 12:14:46 +02:00

Fix compilation

This commit is contained in:
nordsoft 2023-01-15 01:02:41 +04:00
parent f765112798
commit 2acad02476
2 changed files with 1 additions and 11 deletions

View File

@ -28,12 +28,6 @@ VCMI_LIB_NAMESPACE_BEGIN
#define LIL_ENDIAN #define LIL_ENDIAN
#endif #endif
struct ConnectionBuffers
{
boost::asio::streambuf readBuffer;
boost::asio::streambuf writeBuffer;
};
void CConnection::init() void CConnection::init()
{ {
enableSmartPointerSerialization(); enableSmartPointerSerialization();
@ -163,7 +157,6 @@ void CConnection::reportState(vstd::CLoggerBase * out)
CPack * CConnection::retrievePack() CPack * CConnection::retrievePack()
{ {
enableBufferedRead = true;
CPack * pack = nullptr; CPack * pack = nullptr;
iser & pack; iser & pack;
@ -177,7 +170,6 @@ CPack * CConnection::retrievePack()
pack->c = this->shared_from_this(); pack->c = this->shared_from_this();
} }
enableBufferedRead = false;
return pack; return pack;
} }
@ -186,11 +178,9 @@ void CConnection::sendPack(const CPack * pack)
{ {
logNetwork->trace("Sending a pack of type %s", typeid(*pack).name()); logNetwork->trace("Sending a pack of type %s", typeid(*pack).name());
enableBufferedWrite = true;
oser & pack; oser & pack;
flushBuffers();
} }
void CConnection::disableStackSendingByID() void CConnection::disableStackSendingByID()

View File

@ -172,7 +172,7 @@ void CVCMIServer::run()
#endif #endif
if(!lobbyConnectionsThread) if(!lobbyConnectionsThread)
lobbyConnectionsThread = vstd::make_unique<boost::thread>(&CVCMIServer::startAsyncAccept, this); lobbyConnectionsThread = std::make_unique<boost::thread>(&CVCMIServer::startAsyncAccept, this);
/*if(!remoteConnectionsThread && cmdLineOptions.count("lobby")) /*if(!remoteConnectionsThread && cmdLineOptions.count("lobby"))
{ {