Removed many unnecessary copies of NetworkString.

This commit is contained in:
hiker
2015-10-22 21:43:06 +11:00
parent c59f958c2f
commit e6ae208b4f
10 changed files with 50 additions and 41 deletions

View File

@@ -24,7 +24,7 @@ bool GameEventsProtocol::notifyEvent(Event* event)
{
if (event->getType() != EVENT_TYPE_MESSAGE)
return true;
NetworkString data = event->data();
NetworkString &data = event->data();
if (data.size() < 5) // for token and type
{
Log::warn("GameEventsProtocol", "Too short message.");