file: update to 5.45.

This commit is contained in:
Bnyro 2023-07-28 17:15:28 +02:00 committed by Leah Neukirchen
parent 2052bc6584
commit 42fffa7424
2 changed files with 38 additions and 2 deletions

View File

@ -0,0 +1,36 @@
From 218fdf813fd5ccecbb8887a1b62509cd1c6dd3a1 Mon Sep 17 00:00:00 2001
From: Christos Zoulas <christos@zoulas.com>
Date: Fri, 28 Jul 2023 14:38:25 +0000
Subject: [PATCH] deal with 32 bit time_t
---
src/file.h | 8 +++++---
1 file changed, 5 insertions(+), 3 deletions(-)
diff --git a/src/file.h b/src/file.h
index 2e0494d2f..78f574ea1 100644
--- a/src/file.h
+++ b/src/file.h
@@ -27,7 +27,7 @@
*/
/*
* file.h - definitions for file(1) program
- * @(#)$File: file.h,v 1.247 2023/07/27 19:40:22 christos Exp $
+ * @(#)$File: file.h,v 1.248 2023/07/28 14:38:25 christos Exp $
*/
#ifndef __file_h__
@@ -159,9 +159,11 @@
/*
* Dec 31, 23:59:59 9999
* we need to make sure that we don't exceed 9999 because some libc
- * implementations like muslc crash otherwise
+ * implementations like muslc crash otherwise. If you are unlucky
+ * to be running on a system with a 32 bit time_t, then it is even less.
*/
-#define MAX_CTIME CAST(time_t, 0x3afff487cfULL)
+#define MAX_CTIME \
+ CAST(time_t, sizeof(time_t) > 4 ? 0x3afff487cfULL : 0x7fffffffULL)
#define FILE_BADSIZE CAST(size_t, ~0ul)
#define MAXDESC 64 /* max len of text description/MIME type */

View File

@ -1,6 +1,6 @@
# Template file for 'file'
pkgname=file
version=5.44
version=5.45
revision=1
bootstrap=yes
build_style=gnu-configure
@ -11,7 +11,7 @@ maintainer="Enno Boland <gottox@voidlinux.org>"
license="BSD-2-Clause"
homepage="https://www.darwinsys.com/file/"
distfiles="https://astron.com/pub/file/file-${version}.tar.gz"
checksum=3751c7fba8dbc831cb8d7cc8aff21035459b8ce5155ef8b0880a27d028475f3b
checksum=fc97f51029bb0e2c9f4e3bffefdaf678f0e039ee872b9de5c002a6d09c784d82
build_options="libseccomp"