return curl_off_t instead of long long, to work on more platforms
This commit is contained in:
parent
f39749cee4
commit
ad7e26b140
@ -35,15 +35,15 @@ static int get_char(char c, int base);
|
|||||||
* Emulated version of the strtoll function. This extracts a long long
|
* Emulated version of the strtoll function. This extracts a long long
|
||||||
* value from the given input string and returns it.
|
* value from the given input string and returns it.
|
||||||
*/
|
*/
|
||||||
long long
|
curl_off_t
|
||||||
Curl_strtoll(const char *nptr, char **endptr, int base)
|
Curl_strtoll(const char *nptr, char **endptr, int base)
|
||||||
{
|
{
|
||||||
char *end;
|
char *end;
|
||||||
int is_negative = 0;
|
int is_negative = 0;
|
||||||
int overflow;
|
int overflow;
|
||||||
int i;
|
int i;
|
||||||
long long value = 0;
|
curl_off_t value = 0;
|
||||||
long long newval;
|
curl_off_t newval;
|
||||||
|
|
||||||
/* Skip leading whitespace. */
|
/* Skip leading whitespace. */
|
||||||
end = (char *)nptr;
|
end = (char *)nptr;
|
||||||
|
|||||||
@ -37,7 +37,7 @@
|
|||||||
#if HAVE_STRTOLL
|
#if HAVE_STRTOLL
|
||||||
#define strtoofft strtoll
|
#define strtoofft strtoll
|
||||||
#else
|
#else
|
||||||
long long Curl_strtoll(const char *nptr, char **endptr, int base);
|
curl_off_t Curl_strtoll(const char *nptr, char **endptr, int base);
|
||||||
#define strtoofft Curl_strtoll
|
#define strtoofft Curl_strtoll
|
||||||
#define NEED_CURL_STRTOLL
|
#define NEED_CURL_STRTOLL
|
||||||
#endif
|
#endif
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user