In perl.git, the branch blead has been updated <http://perl5.git.perl.org/perl.git/commitdiff/1c5665476f0d7250c7d93f82eab2b7cda1e6937f?hp=0879cd66ef3f00918ae26d9bb7ac555d3911c548>
- Log ----------------------------------------------------------------- commit 1c5665476f0d7250c7d93f82eab2b7cda1e6937f Author: Jarkko Hietaniemi <[email protected]> Date: Sat Oct 1 10:30:29 2016 -0400 Time-HiRes: explicit clockid_t cast for C++11 ----------------------------------------------------------------------- Summary of changes: dist/Time-HiRes/Changes | 3 +++ dist/Time-HiRes/HiRes.pm | 2 +- dist/Time-HiRes/HiRes.xs | 4 ++-- 3 files changed, 6 insertions(+), 3 deletions(-) diff --git a/dist/Time-HiRes/Changes b/dist/Time-HiRes/Changes index e21623b..c308e72 100644 --- a/dist/Time-HiRes/Changes +++ b/dist/Time-HiRes/Changes @@ -1,5 +1,8 @@ Revision history for the Perl extension Time::HiRes. +1.9740_01 [2016-10-01] + - explicit cast to clockid_t needed for C++11 (gcc 6, clang 3.9) + 1.9740 [2016-09-25] - the ext3/ext2 filesystems do not have subsecond resolution, therefore skip the t/utime.t test diff --git a/dist/Time-HiRes/HiRes.pm b/dist/Time-HiRes/HiRes.pm index a4c5002..095aba7 100644 --- a/dist/Time-HiRes/HiRes.pm +++ b/dist/Time-HiRes/HiRes.pm @@ -28,7 +28,7 @@ our @EXPORT_OK = qw (usleep sleep ualarm alarm gettimeofday time tv_interval stat lstat utime ); -our $VERSION = '1.9740'; +our $VERSION = '1.9740_01'; our $XS_VERSION = $VERSION; $VERSION = eval $VERSION; diff --git a/dist/Time-HiRes/HiRes.xs b/dist/Time-HiRes/HiRes.xs index 3a5c7a1..1b9ee23 100644 --- a/dist/Time-HiRes/HiRes.xs +++ b/dist/Time-HiRes/HiRes.xs @@ -1439,7 +1439,7 @@ clock_gettime(clock_id = CLOCK_REALTIME) #ifdef TIME_HIRES_CLOCK_GETTIME_SYSCALL status = syscall(SYS_clock_gettime, clock_id, &ts); #else - status = clock_gettime(clock_id, &ts); + status = clock_gettime((clockid_t)clock_id, &ts); #endif RETVAL = status == 0 ? ts.tv_sec + (NV) ts.tv_nsec / NV_1E9 : -1; @@ -1472,7 +1472,7 @@ clock_getres(clock_id = CLOCK_REALTIME) #ifdef TIME_HIRES_CLOCK_GETRES_SYSCALL status = syscall(SYS_clock_getres, clock_id, &ts); #else - status = clock_getres(clock_id, &ts); + status = clock_getres((clockid_t)clock_id, &ts); #endif RETVAL = status == 0 ? ts.tv_sec + (NV) ts.tv_nsec / NV_1E9 : -1; -- Perl5 Master Repository
