mirror of
https://github.com/luanti-org/luanti.git
synced 2025-06-27 16:36:03 +00:00
Replace NetworkPacket pointers to references
This commit is contained in:
parent
74d34da6cb
commit
083c8c734e
8 changed files with 256 additions and 295 deletions
|
@ -1725,9 +1725,8 @@ void ConnectionSendThread::connect(Address address)
|
|||
|
||||
// Send a dummy packet to server with peer_id = PEER_ID_INEXISTENT
|
||||
m_connection->SetPeerID(PEER_ID_INEXISTENT);
|
||||
NetworkPacket* pkt = new NetworkPacket(0,0);
|
||||
m_connection->Send(PEER_ID_SERVER, 0, pkt, true);
|
||||
delete pkt;
|
||||
NetworkPacket pkt(0,0);
|
||||
m_connection->Send(PEER_ID_SERVER, 0, &pkt, true);
|
||||
}
|
||||
|
||||
void ConnectionSendThread::disconnect()
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue