diff options
Diffstat (limited to 'src/third_party/wiredtiger/src/os_posix/os_strtouq.c')
-rw-r--r-- | src/third_party/wiredtiger/src/os_posix/os_strtouq.c | 24 |
1 files changed, 24 insertions, 0 deletions
diff --git a/src/third_party/wiredtiger/src/os_posix/os_strtouq.c b/src/third_party/wiredtiger/src/os_posix/os_strtouq.c new file mode 100644 index 00000000000..97f9759f76f --- /dev/null +++ b/src/third_party/wiredtiger/src/os_posix/os_strtouq.c @@ -0,0 +1,24 @@ +/*- + * Copyright (c) 2008-2014 WiredTiger, Inc. + * All rights reserved. + * + * See the file LICENSE for redistribution information. + */ + +#include "wt_internal.h" + +/* + * __wt_strtouq -- + * Convert a string to an unsigned quad integer. + */ +uint64_t +__wt_strtouq(const char *nptr, char **endptr, int base) +{ +#if defined(HAVE_STRTOUQ) + return (strtouq(nptr, endptr, base)); +#else + WT_STATIC_ASSERT(sizeof(uint64_t) == sizeof(unsigned long long)); + + return (strtoull(nptr, endptr, base)); +#endif +} |