Increased size of socket buffer
This commit is contained in:
@@ -27,7 +27,8 @@ public:
|
||||
// Check if we are trying to add more than the package can fit.
|
||||
if (m_MaxPacketSize < m_Offset + sizeof(T)) {
|
||||
if (m_MaxPacketSize >= 32000) {
|
||||
LOG_WARNING("Package::WritePrimitive(): New size is huge %i bytes\n", m_MaxPacketSize*2);
|
||||
// This will spam couse 8 players are over 100 000 bytes
|
||||
//LOG_WARNING("Package::WritePrimitive(): New size is huge %i bytes\n", m_MaxPacketSize*2);
|
||||
}
|
||||
resizeData();
|
||||
}
|
||||
|
||||
+3741
-3741
File diff suppressed because it is too large
Load Diff
@@ -15,6 +15,8 @@ bool UDPClient::Connect(std::string playerName, std::string address, int port)
|
||||
}
|
||||
m_ReceiverEndpoint = udp::endpoint(boost::asio::ip::address().from_string(address), port);
|
||||
m_Socket = boost::shared_ptr<boost::asio::ip::udp::socket>(new boost::asio::ip::udp::socket(m_IOService));
|
||||
boost::asio::socket_base::receive_buffer_size option(819200);
|
||||
m_Socket->set_option(option);
|
||||
m_Socket->open(boost::asio::ip::udp::v4());
|
||||
return true;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user