diff options
author | Steve Hay <SteveHay@planit.com> | 2007-08-15 12:44:08 +0000 |
---|---|---|
committer | Steve Hay <SteveHay@planit.com> | 2007-08-15 12:44:08 +0000 |
commit | abbe0d1a8ce49d06f6c93492504db498c69c6b5a (patch) | |
tree | ea0e39190563835267378806352ccdc5b61edc8d /ext | |
parent | a7f43cfc756647d7175b53bd957bd501a9f6ad6d (diff) | |
download | perl-abbe0d1a8ce49d06f6c93492504db498c69c6b5a.tar.gz |
Skip the POSIX::strftime() time test with a 60sec parameter on Vista:
it seems to have the same problem as when built with the VC8 CRT
(Fixes perl #44589)
Also, change the %D to the equivalent %m/%d/%y because %D isn't
supported at all by Microsoft's CRT and just converts to nothing
with VC6's CRT and causes another invalid parameter error with VC8
and Vista
p4raw-id: //depot/perl@31721
Diffstat (limited to 'ext')
-rw-r--r-- | ext/POSIX/t/posix.t | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/ext/POSIX/t/posix.t b/ext/POSIX/t/posix.t index 395daa00e0..93e2602c49 100644 --- a/ext/POSIX/t/posix.t +++ b/ext/POSIX/t/posix.t @@ -173,7 +173,7 @@ ok( &POSIX::acos(1.0) == 0.0, 'dynamic loading' ); # didn't detect it. If this fails, try adding # -DSTRUCT_TM_HASZONE to your cflags when compiling ext/POSIX/POSIX.c. # See ext/POSIX/hints/sunos_4.pl and ext/POSIX/hints/linux.pl -print POSIX::strftime("ok 21 # %H:%M, on %D\n", localtime()); +print POSIX::strftime("ok 21 # %H:%M, on %m/%d/%y\n", localtime()); next_test(); # If that worked, validate the mini_mktime() routine's normalisation of @@ -187,8 +187,10 @@ sub try_strftime { $lc = &POSIX::setlocale(&POSIX::LC_TIME, 'C') if $Config{d_setlocale}; try_strftime("Wed Feb 28 00:00:00 1996 059", 0,0,0, 28,1,96); SKIP: { - skip("VC++ 8 regards 60 seconds as an invalid parameter", 1) - if $Config{cc} eq 'cl' and $Config{ccversion} =~ /^(\d+)/ and $1 >= 14; + skip("VC++ 8 and Vista's CRTs regard 60 seconds as an invalid parameter", 1) + if ($Is_W32 and ($Config{cc} eq 'cl' and + $Config{ccversion} =~ /^(\d+)/ and $1 >= 14) or + ((Win32::GetOSVersion())[1] >= 6)); try_strftime("Thu Feb 29 00:00:60 1996 060", 60,0,-24, 30,1,96); } |