diff options
author | Perttu Ahola <celeron55@gmail.com> | 2012-06-17 02:40:36 +0300 |
---|---|---|
committer | Perttu Ahola <celeron55@gmail.com> | 2012-06-17 02:40:36 +0300 |
commit | d0ea6f9920d30f46d1f5d44e8823a8d932f9f29d (patch) | |
tree | 5b75f389b027a058e1f47fa3103a1cfb51f26b9b /src/mapblock.cpp | |
parent | 1bc37d576ce790c1169c5f9996be7bbc8026db2c (diff) | |
download | minetest-d0ea6f9920d30f46d1f5d44e8823a8d932f9f29d.tar.gz minetest-d0ea6f9920d30f46d1f5d44e8823a8d932f9f29d.tar.bz2 minetest-d0ea6f9920d30f46d1f5d44e8823a8d932f9f29d.zip |
Properly and efficiently use split utility headers
Diffstat (limited to 'src/mapblock.cpp')
-rw-r--r-- | src/mapblock.cpp | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/src/mapblock.cpp b/src/mapblock.cpp index c4d3c422e..efe628a4e 100644 --- a/src/mapblock.cpp +++ b/src/mapblock.cpp @@ -34,6 +34,7 @@ with this program; if not, write to the Free Software Foundation, Inc., #ifndef SERVER #include "mapblock_mesh.h" #endif +#include "util/string.h" #define PP(x) "("<<(x).X<<","<<(x).Y<<","<<(x).Z<<")" @@ -409,7 +410,7 @@ void MapBlock::actuallyUpdateDayNightDiff() void MapBlock::expireDayNightDiff() { - INodeDefManager *nodemgr = m_gamedef->ndef(); + //INodeDefManager *nodemgr = m_gamedef->ndef(); if(data == NULL){ m_day_night_differs = false; @@ -976,7 +977,7 @@ void MapBlock::deSerialize_pre22(std::istream &is, u8 version, bool disk) ("MapBlock::deSerialize: no enough input data"); is_underground = tmp; is.read((char*)*databuf_nodelist, nodecount * ser_length); - if(is.gcount() != nodecount * ser_length) + if((u32)is.gcount() != nodecount * ser_length) throw SerializationError ("MapBlock::deSerialize: no enough input data"); } |