diff --git a/sys-apps/file/file-5.38.recipe b/sys-apps/file/file-5.39.recipe similarity index 96% rename from sys-apps/file/file-5.38.recipe rename to sys-apps/file/file-5.39.recipe index ceee09806..27a7a15c9 100644 --- a/sys-apps/file/file-5.38.recipe +++ b/sys-apps/file/file-5.39.recipe @@ -10,7 +10,7 @@ COPYRIGHT="1986-1999 Ian F. Darwin LICENSE="BSD (2-clause)" REVISION="1" SOURCE_URI="ftp://ftp.astron.com/pub/file/file-$portVersion.tar.gz" -CHECKSUM_SHA256="593c2ffc2ab349c5aea0f55fedfe4d681737b6b62376a9b3ad1e77b2cc19fa34" +CHECKSUM_SHA256="f05d286a76d9556243d0cb05814929c2ecf3a5ba07963f8f70bfaaa70517fad1" PATCHES="file-$portVersion.patchset" ARCHITECTURES="x86_gcc2 x86 x86_64" diff --git a/sys-apps/file/patches/file-5.38.patchset b/sys-apps/file/patches/file-5.39.patchset similarity index 74% rename from sys-apps/file/patches/file-5.38.patchset rename to sys-apps/file/patches/file-5.39.patchset index ae197f6e4..797c9eae3 100644 --- a/sys-apps/file/patches/file-5.38.patchset +++ b/sys-apps/file/patches/file-5.39.patchset @@ -1,14 +1,14 @@ -From 39340b187428922537dbe2a98c12cc249e86b5ae Mon Sep 17 00:00:00 2001 +From 63832b804b7a09fa4a8ccd258bf904f4273430ba Mon Sep 17 00:00:00 2001 From: Jerome Duval Date: Thu, 12 May 2016 19:46:43 +0000 Subject: Haiku patch diff --git a/configure.ac b/configure.ac -index 17505e3..0b7f09a 100644 +index 64c9f42..ddccb86 100644 --- a/configure.ac +++ b/configure.ac -@@ -137,14 +137,14 @@ else +@@ -152,14 +152,14 @@ else WARNINGS="-Wall -Wstrict-prototypes -Wmissing-prototypes -Wpointer-arith \ -Wmissing-declarations -Wredundant-decls -Wnested-externs \ -Wsign-compare -Wreturn-type -Wswitch -Wshadow \ @@ -26,10 +26,10 @@ index 17505e3..0b7f09a 100644 WARNINGS= AC_MSG_RESULT(no) diff --git a/src/der.c b/src/der.c -index cc27769..e77243b 100644 +index 78a056b..6e74bff 100644 --- a/src/der.c +++ b/src/der.c -@@ -219,6 +219,7 @@ static int +@@ -236,6 +236,7 @@ static int der_data(char *buf, size_t blen, uint32_t tag, const void *q, uint32_t len) { const uint8_t *d = CAST(const uint8_t *, q); @@ -37,7 +37,7 @@ index cc27769..e77243b 100644 switch (tag) { case DER_TAG_PRINTABLE_STRING: case DER_TAG_UTF8_STRING: -@@ -229,7 +230,7 @@ der_data(char *buf, size_t blen, uint32_t tag, const void *q, uint32_t len) +@@ -252,7 +253,7 @@ der_data(char *buf, size_t blen, uint32_t tag, const void *q, uint32_t len) break; } @@ -46,31 +46,32 @@ index cc27769..e77243b 100644 uint32_t z = i << 1; if (z < blen - 2) snprintf(buf + z, blen - z, "%.2x", d[i]); -@@ -242,13 +243,14 @@ der_offs(struct magic_set *ms, struct magic *m, size_t nbytes) +@@ -265,6 +266,7 @@ der_offs(struct magic_set *ms, struct magic *m, size_t nbytes) { const uint8_t *b = RCAST(const uint8_t *, ms->search.s); size_t offs = 0, len = ms->search.s_len ? ms->search.s_len : nbytes; + uint32_t tlen; - if (gettag(b, &offs, len) == DER_BAD) - return -1; + if (gettag(b, &offs, len) == DER_BAD) { + DPRINTF(("%s: bad tag 1\n", __func__)); +@@ -273,7 +275,7 @@ der_offs(struct magic_set *ms, struct magic *m, size_t nbytes) DPRINTF(("%s1: %d %" SIZE_T_FORMAT "u %u\n", __func__, ms->offset, offs, m->offset)); - uint32_t tlen = getlength(b, &offs, len); + tlen = getlength(b, &offs, len); - if (tlen == DER_BAD) + if (tlen == DER_BAD) { + DPRINTF(("%s: bad tag 2\n", __func__)); return -1; - DPRINTF(("%s2: %d %" SIZE_T_FORMAT "u %u\n", __func__, ms->offset, -@@ -279,6 +281,7 @@ der_cmp(struct magic_set *ms, struct magic *m) +@@ -306,6 +308,7 @@ der_cmp(struct magic_set *ms, struct magic *m) size_t offs = 0, len = ms->search.s_len; uint32_t tag, tlen; char buf[128]; + size_t slen; - tag = gettag(b, &offs, len); - if (tag == DER_BAD) -@@ -292,7 +295,7 @@ der_cmp(struct magic_set *ms, struct magic *m) + DPRINTF(("%s: compare %zu bytes\n", __func__, len)); + +@@ -328,7 +331,7 @@ der_cmp(struct magic_set *ms, struct magic *m) if ((ms->flags & MAGIC_DEBUG) != 0) fprintf(stderr, "%s: tag %p got=%s exp=%s\n", __func__, b, buf, s); @@ -80,10 +81,10 @@ index cc27769..e77243b 100644 if (strncmp(buf, s, slen) != 0) return 0; diff --git a/src/readelf.c b/src/readelf.c -index 909e414..0bf4904 100644 +index cf1dc91..8039000 100644 --- a/src/readelf.c +++ b/src/readelf.c -@@ -980,6 +980,7 @@ do_auxv_note(struct magic_set *ms, unsigned char *nbuf, uint32_t type, +@@ -1005,6 +1005,7 @@ do_auxv_note(struct magic_set *ms, unsigned char *nbuf, uint32_t type, const char *tag; int is_string; size_t nval; @@ -91,7 +92,7 @@ index 909e414..0bf4904 100644 if ((*flags & (FLAGS_IS_CORE|FLAGS_DID_CORE_STYLE)) != (FLAGS_IS_CORE|FLAGS_DID_CORE_STYLE)) -@@ -1007,7 +1008,7 @@ do_auxv_note(struct magic_set *ms, unsigned char *nbuf, uint32_t type, +@@ -1032,7 +1033,7 @@ do_auxv_note(struct magic_set *ms, unsigned char *nbuf, uint32_t type, *flags |= FLAGS_DID_AUXV; nval = 0; @@ -101,5 +102,5 @@ index 909e414..0bf4904 100644 /* Limit processing to 50 vector entries to prevent DoS */ if (nval++ >= 50) { -- -2.17.0 +2.28.0