* Patch to make tar shut up about timestamps of 0 (1-1-1970 00:00:00

UTC).  (NIXPKGS-46)

svn path=/nixpkgs/trunk/; revision=8743
This commit is contained in:
Eelco Dolstra 2007-05-24 13:35:44 +00:00
parent c44f77bbdf
commit fe25567984
2 changed files with 21 additions and 0 deletions

View file

@ -6,4 +6,5 @@ stdenv.mkDerivation {
url = ftp://ftp.nluug.nl/pub/gnu/tar/tar-1.16.1.tar.bz2;
md5 = "d51593461c5ef1f7e37134f22338bb9e";
};
patches = [./implausible.patch];
}

View file

@ -0,0 +1,20 @@
diff -rc tar-1.16.1-orig/src/extract.c tar-1.16.1/src/extract.c
*** tar-1.16.1-orig/src/extract.c 2006-12-07 14:26:00.000000000 +0100
--- tar-1.16.1/src/extract.c 2007-05-24 11:39:47.000000000 +0200
***************
*** 194,200 ****
static void
check_time (char const *file_name, struct timespec t)
{
! if (t.tv_sec <= 0)
WARN ((0, 0, _("%s: implausibly old time stamp %s"),
file_name, tartime (t, true)));
else if (timespec_cmp (volume_start_time, t) < 0)
--- 194,200 ----
static void
check_time (char const *file_name, struct timespec t)
{
! if (0 /* t.tv_sec <= 0 */)
WARN ((0, 0, _("%s: implausibly old time stamp %s"),
file_name, tartime (t, true)));
else if (timespec_cmp (volume_start_time, t) < 0)