types: remove curl_int64_t/curl_uint64_t

These types and the definitions surrounding them are no longer needed.

Closes #19706
This commit is contained in:
Stefan Eissing 2025-11-26 12:02:02 +01:00 committed by Daniel Stenberg
parent 0b09ad8ecb
commit 94ce87c391
No known key found for this signature in database
GPG key ID: 5CC908FDB71E12C2
4 changed files with 97 additions and 112 deletions

View file

@ -31,16 +31,16 @@
struct timeval tvrealnow(void)
{
/* UNIX EPOCH (1970-01-01) in FILETIME (1601-01-01) as 64-bit value */
static const curl_uint64_t EPOCH = (curl_uint64_t)116444736000000000ULL;
static const uint64_t EPOCH = UINT64_C(116444736000000000);
SYSTEMTIME systime;
FILETIME ftime; /* 100ns since 1601-01-01, as double 32-bit value */
curl_uint64_t time; /* 100ns since 1601-01-01, as 64-bit value */
uint64_t time; /* 100ns since 1601-01-01, as 64-bit value */
struct timeval now;
GetSystemTime(&systime);
SystemTimeToFileTime(&systime, &ftime);
time = ((curl_uint64_t)ftime.dwLowDateTime);
time += ((curl_uint64_t)ftime.dwHighDateTime) << 32;
time = ((uint64_t)ftime.dwLowDateTime);
time += ((uint64_t)ftime.dwHighDateTime) << 32;
now.tv_sec = (long)((time - EPOCH) / 10000000L); /* unit is 100ns */
now.tv_usec = (long)(systime.wMilliseconds * 1000);