aboutsummaryrefslogtreecommitdiff
path: root/sysdeps/unix/sysv/linux/alpha
diff options
context:
space:
mode:
authorLukasz Majewski <lukma@denx.de>2020-03-16 08:31:41 +0100
committerLukasz Majewski <lukma@denx.de>2020-05-20 16:45:16 +0200
commite9698175b0b60407db1e89bcf29437ab224bca0b (patch)
treecb1b6779101327e185e1868b5200cc8a06e98c0b /sysdeps/unix/sysv/linux/alpha
parent5b9b177bf62bcdaf42255f88ad9ebf090528c5e1 (diff)
downloadglibc-e9698175b0b60407db1e89bcf29437ab224bca0b.tar
glibc-e9698175b0b60407db1e89bcf29437ab224bca0b.tar.gz
glibc-e9698175b0b60407db1e89bcf29437ab224bca0b.tar.bz2
glibc-e9698175b0b60407db1e89bcf29437ab224bca0b.zip
y2038: Replace __clock_gettime with __clock_gettime64
The __clock_gettime internal function is not supporting 64 bit time on architectures with __WORDSIZE == 32 and __TIMESIZE != 64 (like e.g. ARM 32 bit). The __clock_gettime64 function shall be used instead in the glibc itself as it supports 64 bit time on those systems. This patch does not bring any changes to systems with __WORDSIZE == 64 as for them the __clock_gettime64 is aliased to __clock_gettime (in ./include/time.h).
Diffstat (limited to 'sysdeps/unix/sysv/linux/alpha')
-rw-r--r--sysdeps/unix/sysv/linux/alpha/osf_gettimeofday.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/sysdeps/unix/sysv/linux/alpha/osf_gettimeofday.c b/sysdeps/unix/sysv/linux/alpha/osf_gettimeofday.c
index 8cf5d303f9..5075ae0444 100644
--- a/sysdeps/unix/sysv/linux/alpha/osf_gettimeofday.c
+++ b/sysdeps/unix/sysv/linux/alpha/osf_gettimeofday.c
@@ -35,8 +35,8 @@ __gettimeofday_tv32 (struct __timeval32 *restrict tv32, void *restrict tz)
if (__glibc_unlikely (tz != 0))
memset (tz, 0, sizeof (struct timezone));
- struct timespec ts;
- __clock_gettime (CLOCK_REALTIME, &ts);
+ struct __timespec64 ts;
+ __clock_gettime64 (CLOCK_REALTIME, &ts);
*tv32 = valid_timespec_to_timeval32 (ts);
return 0;