1
0
Fork 0
mirror of https://github.com/luanti-org/luanti.git synced 2025-06-27 16:36:03 +00:00

Network part requires SharedBuffers to be pass as value

This can trigger unreproductible crashes due to concurrency problem on SharedBuffers

This fixes #6354
This commit is contained in:
Loic Blot 2017-09-03 19:01:53 +02:00
parent 2ac5a45faa
commit eabf04bd34
No known key found for this signature in database
GPG key ID: EFAA458E8C153987
4 changed files with 8 additions and 10 deletions

View file

@ -330,7 +330,7 @@ void ConnectionSendThread::sendAsPacketReliable(BufferedPacket &p, Channel *chan
}
bool ConnectionSendThread::rawSendAsPacket(u16 peer_id, u8 channelnum,
const SharedBuffer<u8> &data, bool reliable)
SharedBuffer<u8> data, bool reliable)
{
PeerHelper peer = m_connection->getPeerNoEx(peer_id);
if (!peer) {