summaryrefslogtreecommitdiff
path: root/community/pkgfile
diff options
context:
space:
mode:
authorroot <root@rshg054.dnsready.net>2012-11-23 02:33:48 -0800
committerroot <root@rshg054.dnsready.net>2012-11-23 02:33:48 -0800
commit1fce42e9327109bd47dba5e3e690144a23bbbc19 (patch)
treee48f488b533fcfa9f4e29f6d2b935e57adf0a178 /community/pkgfile
parent13c6302fab6118693af345756375923b9fb7da69 (diff)
Fri Nov 23 02:31:09 PST 2012
Diffstat (limited to 'community/pkgfile')
-rw-r--r--community/pkgfile/0001-update-fix-use-after-free.patch27
-rw-r--r--community/pkgfile/PKGBUILD13
2 files changed, 36 insertions, 4 deletions
diff --git a/community/pkgfile/0001-update-fix-use-after-free.patch b/community/pkgfile/0001-update-fix-use-after-free.patch
new file mode 100644
index 000000000..4494224c5
--- /dev/null
+++ b/community/pkgfile/0001-update-fix-use-after-free.patch
@@ -0,0 +1,27 @@
+From 60559a15e170ad49b388ee442eb2ccbe483bc9aa Mon Sep 17 00:00:00 2001
+From: Dave Reisner <dreisner@archlinux.org>
+Date: Mon, 19 Nov 2012 19:50:47 -0500
+Subject: [PATCH] update: fix use after free
+
+mark the address space as unread so that we don't attempt a double free
+on a repo download failure during the final cleanup.
+---
+ src/update.c | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/src/update.c b/src/update.c
+index c2e76e5..0b4fb8a 100644
+--- a/src/update.c
++++ b/src/update.c
+@@ -552,7 +552,7 @@ static int add_repo_download(CURLM *multi, struct repo_t *repo)
+ } else {
+ curl_multi_remove_handle(multi, repo->curl);
+ FREE(repo->url);
+- free(repo->data);
++ FREE(repo->data);
+ repo->buflen = 0;
+ repo->server_idx++;
+ }
+--
+1.8.0
+
diff --git a/community/pkgfile/PKGBUILD b/community/pkgfile/PKGBUILD
index 1ab0717c3..5f176cdb0 100644
--- a/community/pkgfile/PKGBUILD
+++ b/community/pkgfile/PKGBUILD
@@ -1,9 +1,9 @@
-# $Id: PKGBUILD 80220 2012-11-17 22:28:33Z dreisner $
+# $Id: PKGBUILD 80498 2012-11-23 00:24:41Z dreisner $
# Maintainer: Dave Reisner <dreisner@archlinux.org>
pkgname=pkgfile
pkgver=7
-pkgrel=1
+pkgrel=2
pkgdesc="a pacman .files metadata explorer"
arch=('i686' 'x86_64')
url="http://github.com/falconindy/pkgfile"
@@ -11,13 +11,18 @@ license=('MIT')
depends=('libarchive' 'curl' 'pcre' 'pacman')
conflicts=('pkgtools<24-2')
makedepends=('perl')
-source=("https://github.com/downloads/falconindy/$pkgname/$pkgname-$pkgver.tar.xz"{,.sig})
+source=("https://github.com/downloads/falconindy/$pkgname/$pkgname-$pkgver.tar.xz"{,.sig}
+ '0001-update-fix-use-after-free.patch')
install=pkgfile.install
md5sums=('f1dc0052b1c21597ea2fa0f0ce05608c'
- '28599a9b6e56860a9cba1c95ec797551')
+ '28599a9b6e56860a9cba1c95ec797551'
+ 'a4f505d080795fd0c10fd1d93b4520f6')
build() {
cd "$pkgname-$pkgver"
+
+ patch -Np1 <"$srcdir/0001-update-fix-use-after-free.patch"
+
./configure
make