Put a category enabled filter on default switch case so we're not chewing up extra cpu cycles

This commit is contained in:
Akkadius 2017-02-13 01:26:19 -06:00
parent a81212e1b4
commit 92d4468326

View File

@ -99,9 +99,11 @@ bool Client::Process()
} }
default: default:
{ {
char dump[64]; if (Log.log_settings[Logs::Client_Server_Packet_Unhandled].is_category_enabled == 1) {
app->build_header_dump(dump); char dump[64];
Log.Out(Logs::General, Logs::Error, "Recieved unhandled application packet from the client: %s.", dump); app->build_header_dump(dump);
Log.Out(Logs::General, Logs::Error, "Recieved unhandled application packet from the client: %s.", dump);
}
} }
} }