]> git.ipfire.org Git - thirdparty/tor.git/commitdiff
Don't fall back to _atoi64
authorNick Mathewson <nickm@torproject.org>
Wed, 9 Aug 2017 13:58:16 +0000 (09:58 -0400)
committerNick Mathewson <nickm@torproject.org>
Mon, 28 Aug 2017 14:21:29 +0000 (10:21 -0400)
We only did this on windows when building with MSVC 6 and earlier,
which is now considered a screamingly bad idea.

src/common/util.c

index 0858d17fe6726b94aea2860d6f0d48450553d68e..9cd9ebdc4d8597b6b25156f9bee21fed46d8bea3 100644 (file)
@@ -1233,15 +1233,7 @@ tor_parse_uint64(const char *s, int base, uint64_t min,
 #ifdef HAVE_STRTOULL
   r = (uint64_t)strtoull(s, &endptr, base);
 #elif defined(_WIN32)
-#if defined(_MSC_VER) && _MSC_VER < 1300
-  tor_assert(base <= 10);
-  r = (uint64_t)_atoi64(s);
-  endptr = (char*)s;
-  while (TOR_ISSPACE(*endptr)) endptr++;
-  while (TOR_ISDIGIT(*endptr)) endptr++;
-#else
   r = (uint64_t)_strtoui64(s, &endptr, base);
-#endif
 #elif SIZEOF_LONG == 8
   r = (uint64_t)strtoul(s, &endptr, base);
 #else