Skip to content

Commit

Permalink
Network: Delete copy constructor and use std::move instead (#11642)
Browse files Browse the repository at this point in the history
This is a follow-up change which disables class copies where possible to avoid unnecessary memory movements.
  • Loading branch information
SmallJoker committed Dec 1, 2021
1 parent 1dc1305 commit 57a59ae
Show file tree
Hide file tree
Showing 7 changed files with 600 additions and 552 deletions.
2 changes: 1 addition & 1 deletion src/client/client.cpp
Expand Up @@ -877,7 +877,7 @@ void Client::ProcessData(NetworkPacket *pkt)
*/
if(sender_peer_id != PEER_ID_SERVER) {
infostream << "Client::ProcessData(): Discarding data not "
"coming from server: peer_id=" << sender_peer_id
"coming from server: peer_id=" << sender_peer_id << " command=" << pkt->getCommand()
<< std::endl;
return;
}
Expand Down

0 comments on commit 57a59ae

Please sign in to comment.