Fix Windows portability issue in 23a27b039d94ba35.

_strtoui64() is available in MSVC builds, but apparently not with
other Windows toolchains.  Thanks to Petr Jelinek for the diagnosis.
This commit is contained in:
Tom Lane 2016-03-12 22:34:47 -05:00
parent fc7a9dfddb
commit ab737f6ba9

View File

@ -402,7 +402,7 @@ pg_ltostr(char *str, int32 value)
uint64
pg_strtouint64(const char *str, char **endptr, int base)
{
#ifdef WIN32
#ifdef _MSC_VER /* MSVC only */
return _strtoui64(str, endptr, base);
#elif defined(HAVE_STRTOULL) && SIZEOF_LONG < 8
return strtoull(str, endptr, base);