From: AZero13 Date: Mon, 19 May 2025 17:39:32 +0000 (-0400) Subject: days should be a long type X-Git-Tag: v3.8.0~6^2 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=refs%2Fpull%2F2619%2Fhead;p=thirdparty%2Flibarchive.git days should be a long type The difference in years is cast to a long and then multiplied by 365. The return value of the function is also a long. --- diff --git a/libarchive/archive_parse_date.c b/libarchive/archive_parse_date.c index f907bf20a..cda0b11a5 100644 --- a/libarchive/archive_parse_date.c +++ b/libarchive/archive_parse_date.c @@ -928,7 +928,7 @@ difftm (struct tm *a, struct tm *b) { int ay = a->tm_year + (TM_YEAR_ORIGIN - 1); int by = b->tm_year + (TM_YEAR_ORIGIN - 1); - int days = ( + long days = ( /* difference in day of year */ a->tm_yday - b->tm_yday /* + intervening leap days */