summaryrefslogtreecommitdiff
path: root/src/mapblock.cpp
diff options
context:
space:
mode:
authorShadowNinja <shadowninja@minetest.net>2015-10-14 02:39:30 -0400
committerkwolekr <kwolekr@minetest.net>2015-10-14 02:39:37 -0400
commit6f2d785d0ff761961912d7e79a7d16c4adf86861 (patch)
tree3b96b197cc58b3a4bd30663cb66cf2aca630e77d /src/mapblock.cpp
parent6f4d6cb5741d10e10dacc78e264e421bf6a297cf (diff)
downloadminetest-6f2d785d0ff761961912d7e79a7d16c4adf86861.tar.gz
minetest-6f2d785d0ff761961912d7e79a7d16c4adf86861.tar.bz2
minetest-6f2d785d0ff761961912d7e79a7d16c4adf86861.zip
Rename macros with two leading underscores
These names are reserved for the compiler/library implementations.
Diffstat (limited to 'src/mapblock.cpp')
-rw-r--r--src/mapblock.cpp12
1 files changed, 6 insertions, 6 deletions
diff --git a/src/mapblock.cpp b/src/mapblock.cpp
index be16c3bb7..f8747f52b 100644
--- a/src/mapblock.cpp
+++ b/src/mapblock.cpp
@@ -796,12 +796,12 @@ void MapBlock::deSerialize_pre22(std::istream &is, u8 version, bool disk)
char tmp;
is.read(&tmp, 1);
if (is.gcount() != 1)
- throw SerializationError(std::string(__FUNCTION_NAME)
+ throw SerializationError(std::string(FUNCTION_NAME)
+ ": not enough input data");
is_underground = tmp;
is.read((char *)*databuf_nodelist, nodecount * ser_length);
if ((u32)is.gcount() != nodecount * ser_length)
- throw SerializationError(std::string(__FUNCTION_NAME)
+ throw SerializationError(std::string(FUNCTION_NAME)
+ ": not enough input data");
} else if (version <= 10) {
u8 t8;
@@ -814,7 +814,7 @@ void MapBlock::deSerialize_pre22(std::istream &is, u8 version, bool disk)
decompress(is, os, version);
std::string s = os.str();
if (s.size() != nodecount)
- throw SerializationError(std::string(__FUNCTION_NAME)
+ throw SerializationError(std::string(FUNCTION_NAME)
+ ": not enough input data");
for (u32 i = 0; i < s.size(); i++) {
databuf_nodelist[i*ser_length] = s[i];
@@ -826,7 +826,7 @@ void MapBlock::deSerialize_pre22(std::istream &is, u8 version, bool disk)
decompress(is, os, version);
std::string s = os.str();
if (s.size() != nodecount)
- throw SerializationError(std::string(__FUNCTION_NAME)
+ throw SerializationError(std::string(FUNCTION_NAME)
+ ": not enough input data");
for (u32 i = 0; i < s.size(); i++) {
databuf_nodelist[i*ser_length + 1] = s[i];
@@ -839,7 +839,7 @@ void MapBlock::deSerialize_pre22(std::istream &is, u8 version, bool disk)
decompress(is, os, version);
std::string s = os.str();
if (s.size() != nodecount)
- throw SerializationError(std::string(__FUNCTION_NAME)
+ throw SerializationError(std::string(FUNCTION_NAME)
+ ": not enough input data");
for (u32 i = 0; i < s.size(); i++) {
databuf_nodelist[i*ser_length + 2] = s[i];
@@ -859,7 +859,7 @@ void MapBlock::deSerialize_pre22(std::istream &is, u8 version, bool disk)
decompress(is, os, version);
std::string s = os.str();
if (s.size() != nodecount * 3)
- throw SerializationError(std::string(__FUNCTION_NAME)
+ throw SerializationError(std::string(FUNCTION_NAME)
+ ": decompress resulted in size other than nodecount*3");
// deserialize nodes from buffer