diff options
author | ShadowNinja <shadowninja@minetest.net> | 2014-03-12 19:37:19 -0400 |
---|---|---|
committer | ShadowNinja <shadowninja@minetest.net> | 2014-03-12 19:37:19 -0400 |
commit | 18577f25277f269c8dd8d2bdcaaccbac72d9370d (patch) | |
tree | 094926c06f9c5943433f846a8257699c59a19b50 /src/util | |
parent | 7cac34c807b6f38eaca3bc8296566493c8874e03 (diff) | |
download | minetest-18577f25277f269c8dd8d2bdcaaccbac72d9370d.tar.gz minetest-18577f25277f269c8dd8d2bdcaaccbac72d9370d.tar.bz2 minetest-18577f25277f269c8dd8d2bdcaaccbac72d9370d.zip |
Replace usage of long long with u64/s64
Diffstat (limited to 'src/util')
-rw-r--r-- | src/util/serialize.cpp | 3 | ||||
-rw-r--r-- | src/util/string.h | 2 |
2 files changed, 3 insertions, 2 deletions
diff --git a/src/util/serialize.cpp b/src/util/serialize.cpp index 126385007..58f569fb7 100644 --- a/src/util/serialize.cpp +++ b/src/util/serialize.cpp @@ -22,6 +22,7 @@ with this program; if not, write to the Free Software Foundation, Inc., #include "porting.h" #include "util/string.h" #include "../exceptions.h" +#include "../irrlichttypes.h" #include <sstream> #include <iomanip> @@ -428,7 +429,7 @@ bool serializeStructToString(std::string *outstr, bufpos += PADDING(bufpos, u64); nprinted = snprintf(sbuf + pos, sbuflen, is_unsigned ? "%llu, " : "%lli, ", - (unsigned long long)*((u64 *)bufpos)); + *((u64 *)bufpos)); bufpos += sizeof(u64); } break; diff --git a/src/util/string.h b/src/util/string.h index 9bb89f14a..bed66417e 100644 --- a/src/util/string.h +++ b/src/util/string.h @@ -165,7 +165,7 @@ inline s32 mystoi(const std::string &s, s32 min, s32 max) inline s64 stoi64(const std::string &s) { std::stringstream tmp(s); - long long t; + s64 t; tmp >> t; return t; } |