From 3ed9957a804672665787bc9fd28e3e6be1d751d0 Mon Sep 17 00:00:00 2001 From: Rijn Buve Date: Mon, 27 Jul 2015 15:00:35 +0200 Subject: [PATCH] Revert "Removed long to int warnings and unused variables" --- utility/mapcode.cpp | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/utility/mapcode.cpp b/utility/mapcode.cpp index bc023df..bfe84bc 100644 --- a/utility/mapcode.cpp +++ b/utility/mapcode.cpp @@ -47,7 +47,7 @@ #undef LIMIT_TO_MICRODEGREES #define my_isnan(x) (false) -#define my_round(x) ((int) (floor((x) + 0.5))) +#define my_round(x) ((long) (floor((x) + 0.5))) static int selfCheckEnabled = 0; @@ -456,7 +456,7 @@ int main(const int argc, const char** argv) const char* suffix = strstr(mapcode, "-"); extraDigits = 0; if (suffix != 0) { - extraDigits = (int) (strlen(suffix) - 1); + extraDigits = strlen(suffix) - 1; } selfCheckLatLonToMapcode(lat, lon, defaultTerritory, mapcode, extraDigits); } @@ -651,7 +651,7 @@ int main(const int argc, const char** argv) srand(seed); } else { - srand((unsigned int) time(0)); + srand(time(0)); } } useXYZ = (strstr(cmd, "XYZ") != 0);