From 3d0eced7e7284506e91d94ff01470d64ee6a98a9 Mon Sep 17 00:00:00 2001 From: "madmaxoft@gmail.com" Date: Tue, 6 Mar 2012 21:48:45 +0000 Subject: ChunkSender won't send NULL packets anymore git-svn-id: http://mc-server.googlecode.com/svn/trunk@376 0a769ca7-a7f5-676a-18bf-c427514a06d6 --- source/ChunkSender.cpp | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) (limited to 'source') diff --git a/source/ChunkSender.cpp b/source/ChunkSender.cpp index 47d84d166..3a664962d 100644 --- a/source/ChunkSender.cpp +++ b/source/ChunkSender.cpp @@ -186,7 +186,11 @@ void cChunkSender::BlockData(const char * a_Data) void cChunkSender::BlockEntity(cBlockEntity * a_Entity) { - m_Packets.push_back(a_Entity->GetPacket()); + cPacket * Packet = a_Entity->GetPacket(); + if (Packet != NULL) + { + m_Packets.push_back(Packet); + } } -- cgit v1.2.3