diff --git a/src/test/fuzz/locale.cpp b/src/test/fuzz/locale.cpp --- a/src/test/fuzz/locale.cpp +++ b/src/test/fuzz/locale.cpp @@ -803,7 +803,6 @@ ParseInt64(random_string, &parseint64_out_without_locale); const int64_t atoi64_without_locale = atoi64(random_string); const int atoi_without_locale = atoi(random_string); - const int64_t atoi64c_without_locale = atoi64(random_string.c_str()); const int64_t random_int64 = fuzzed_data_provider.ConsumeIntegral(); const std::string tostring_without_locale = ToString(random_int64); @@ -839,8 +838,6 @@ } const int64_t atoi64_with_locale = atoi64(random_string); assert(atoi64_without_locale == atoi64_with_locale); - const int64_t atoi64c_with_locale = atoi64(random_string.c_str()); - assert(atoi64c_without_locale == atoi64c_with_locale); const int atoi_with_locale = atoi(random_string); assert(atoi_without_locale == atoi_with_locale); const std::string tostring_with_locale = ToString(random_int64); diff --git a/src/util/strencodings.h b/src/util/strencodings.h --- a/src/util/strencodings.h +++ b/src/util/strencodings.h @@ -62,7 +62,6 @@ std::string EncodeBase32(const std::string &str); void SplitHostPort(std::string in, int &portOut, std::string &hostOut); -int64_t atoi64(const char *psz); int64_t atoi64(const std::string &str); int atoi(const std::string &str); diff --git a/src/util/strencodings.cpp b/src/util/strencodings.cpp --- a/src/util/strencodings.cpp +++ b/src/util/strencodings.cpp @@ -451,14 +451,6 @@ return out.str(); } -int64_t atoi64(const char *psz) { -#ifdef _MSC_VER - return _atoi64(psz); -#else - return strtoll(psz, nullptr, 10); -#endif -} - int64_t atoi64(const std::string &str) { #ifdef _MSC_VER return _atoi64(str.c_str()); diff --git a/src/wallet/wallet.h b/src/wallet/wallet.h --- a/src/wallet/wallet.h +++ b/src/wallet/wallet.h @@ -232,7 +232,7 @@ return; } - nOrderPos = atoi64(mapValue["n"].c_str()); + nOrderPos = atoi64(mapValue["n"]); } static inline void WriteOrderPos(const int64_t &nOrderPos,