Re: [ANNOUNCE] Git v2.9.1

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hi Peff,

On Tue, 12 Jul 2016, Jeff King wrote:

> On Tue, Jul 12, 2016 at 09:30:28AM +0200, Johannes Schindelin wrote:
> 
> > FWIW I have this monster patch as a starting point (I plan to work more on
> > this today):
> 
> Cool! Thanks for working on this.

Well, I had to. Git for Windows v2.9.1 needs to get released, and I won't
do that with a failing test suite.

> I suspect we should still do something about skipping those tests,
> though, if only because the v2.9.x maint track is broken, and switching
> to time_t is a sufficiently large change that we probably don't want it
> for maint (it _seems_ like it shouldn't cause any problems, but I'm
> wondering if we might inadvertently trigger funny issues around
> signedness or something).

I totally agree that this patch is very, very large. And yeah, this change
is intrusive enough that it should not hit maint (but then, IMO neither
should the change that triggered this test failure have hit maint).

So I think I'll go with this for the moment (as we all know, my patch
series often go through a couple of commenting rounds, and are not always
picked up quickly, and I do not wait that long with Git for Windows
v2.9.1):

-- snipsnap --
[PATCH] Work around test failures due to timestamps being unsigned long

Git's source code refers to timestamps as unsigned longs. On 32-bit
platforms, as well as on Windows, unsigned long is not large enough to
capture dates that are "absurdly far in the future".

While we will fix this issue properly by replacing unsigned long ->
time_t, on the maint track we want to be a bit more conservative and
just skip those tests.

Signed-off-by: Johannes Schindelin <johannes.schindelin@xxxxxx>
---
 t/t0006-date.sh | 15 +++++++++++----
 1 file changed, 11 insertions(+), 4 deletions(-)

diff --git a/t/t0006-date.sh b/t/t0006-date.sh
index 04ce535..d185640 100755
--- a/t/t0006-date.sh
+++ b/t/t0006-date.sh
@@ -48,10 +48,17 @@ check_show default "$TIME" 'Wed Jun 15 16:13:20 2016 +0200'
 check_show raw "$TIME" '1466000000 +0200'
 check_show iso-local "$TIME" '2016-06-15 14:13:20 +0000'
 
-# arbitrary time absurdly far in the future
-FUTURE="5758122296 -0400"
-check_show iso       "$FUTURE" "2152-06-19 18:24:56 -0400"
-check_show iso-local "$FUTURE" "2152-06-19 22:24:56 +0000"
+case "$(test-date show:iso 9999999999)" in
+*2038*)
+	# on this platform, unsigned long is 32-bit, i.e. not large enough
+	;;
+*)
+	# arbitrary time absurdly far in the future
+	FUTURE="5758122296 -0400"
+	check_show iso       "$FUTURE" "2152-06-19 18:24:56 -0400"
+	check_show iso-local "$FUTURE" "2152-06-19 22:24:56 +0000"
+	;;
+esac
 
 check_parse() {
 	echo "$1 -> $2" >expect
-- 
2.9.0.278.g1caae67

--
To unsubscribe from this list: send the line "unsubscribe git" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html



[Index of Archives]     [Linux Kernel Development]     [Gcc Help]     [IETF Annouce]     [DCCP]     [Netdev]     [Networking]     [Security]     [V4L]     [Bugtraq]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux SCSI]     [Fedora Users]