This is the mail archive of the
libc-alpha@sourceware.org
mailing list for the glibc project.
Re: Fifth draft of the Y2038 design document
Hi Joseph,
On Fri, 10 Mar 2017 00:29:51 +0000, Joseph Myers
<joseph@codesourcery.com> wrote :
> On Fri, 10 Mar 2017, Albert ARIBAUD wrote:
>
> > #else
> > # ifdef __REDIRECT
> > extern int __REDIRECT(clock_gettime,(clockid_t __clock_id, struct timespec *__tp),clock_gettime64) __THROW;
> > # else
> > # define clock_gettime clock_gettime64
>
> No, both of those should reference the implementation-namespace
> __clock_gettime64, which should be exported at a public symbol version
> (and there shouldn't be a clock_gettime64 alias without clear evidence for
> the need for a clock_gettime64 API for using 64-bit times in an
> application built for 32-bit times by default).
So this should be ok?
#ifndef __USE_TIME_BITS64
extern int clock_gettime (clockid_t __clock_id, struct timespec *__tp) __THROW;
#else
# ifdef __REDIRECT
extern int __REDIRECT(clock_gettime,(clockid_t __clock_id, struct timespec *__tp),__clock_gettime64) __THROW;
# else
# define clock_gettime __clock_gettime64
# endif
#endif
Cordialement,
Albert ARIBAUD
3ADEV