Fixed net_nop causing empty lines in output

This commit is contained in:
Jordan Cristiano 2015-05-15 01:03:59 -04:00
parent 063c2f515c
commit 2e8c0a742f

View File

@ -58,7 +58,10 @@ void ConLogWriter::WriteNetPacket(NetPacket& packet)
{
std::ostringstream ss;
NetHandlers::NetMsg_ToString(packet.type, ss, packet.data);
ss << "\n";
fputs(ss.str().c_str(), m_outputFp);
std::clog << ss.str();
if (ss.tellp() > 0)
{
ss << "\n";
fputs(ss.str().c_str(), m_outputFp);
std::clog << ss.str();
}
}