file: Update to 5.18

This commit is contained in:
Alexpux
2014-03-29 18:16:52 +04:00
parent 6e947c2f47
commit 4023b9d946
2 changed files with 6 additions and 34 deletions

View File

@@ -1,8 +1,8 @@
# Maintainer: Alexey Pavlov <alexpux@gmail.com>
pkgname=file
pkgver=5.17
pkgrel=2
pkgver=5.18
pkgrel=1
pkgdesc="File type identification utility"
arch=('i686' 'x86_64')
license=('custom')
@@ -12,19 +12,16 @@ depends=('zlib')
makedepends=('python2' 'python3' 'zlib-devel')
options=('!libtool')
source=(ftp://ftp.astron.com/pub/${pkgname}/${pkgname}-${pkgver}.tar.gz
file-5.17-msys2.patch
file-5.15-fix-regexp.patch
file-5.17-off-by-one.patch)
md5sums=('e19c47e069ced7b01ccb4db402cc01d3'
file-5.17-msys2.patch
file-5.15-fix-regexp.patch)
md5sums=('d420d8f2990cd344673acfbf8d76ff5a'
'1538c425504bce1cd01126a385b70eb1'
'f29d52a9c614967b5f3c7d67f0983103'
'f36a87784f1db2e415ce09badb38fbe8')
'f29d52a9c614967b5f3c7d67f0983103')
prepare() {
cd "${srcdir}/${pkgname}-${pkgver}"
patch -p1 -i ${srcdir}/file-5.17-msys2.patch
patch -p1 -i ${srcdir}/file-5.15-fix-regexp.patch
patch -p1 -i ${srcdir}/file-5.17-off-by-one.patch
autoreconf -fi
}

View File

@@ -1,25 +0,0 @@
From 70c65d2e1841491f59168db1f905e8b14083fb1c Mon Sep 17 00:00:00 2001
From: Christos Zoulas <christos@zoulas.com>
Date: Tue, 4 Mar 2014 17:42:19 +0000
Subject: [PATCH] off by one in out of bounds calculations (Jan Kaluza)
---
src/softmagic.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/src/softmagic.c b/src/softmagic.c
index 170de95..5ed3998 100644
--- a/src/softmagic.c
+++ b/src/softmagic.c
@@ -72,7 +72,7 @@ private int mcopy(struct magic_set *, union VALUETYPE *, int, int,
private void cvt_32(union VALUETYPE *, const struct magic *);
private void cvt_64(union VALUETYPE *, const struct magic *);
-#define OFFSET_OOB(n, o, i) ((n) < (o) || (i) >= ((n) - (o)))
+#define OFFSET_OOB(n, o, i) ((n) < (o) || (i) > ((n) - (o)))
/*
* softmagic - lookup one file in parsed, in-memory copy of database
* Passed the name and FILE * of one file to be typed.
--
1.8.5.5