summaryrefslogtreecommitdiffstats
path: root/main/collectd
diff options
context:
space:
mode:
authorTimo Teräs <timo.teras@iki.fi>2014-06-20 12:04:49 +0300
committerTimo Teräs <timo.teras@iki.fi>2014-06-20 12:05:48 +0300
commit480a758e59bbe099af01d90f36e117d4342a3a18 (patch)
treebef40877ef7266dd174815d97d5497a7d6559bb6 /main/collectd
parent0cb0ad9ce90393df00c30433b41bab979a1abb3f (diff)
downloadaports-480a758e59bbe099af01d90f36e117d4342a3a18.tar.bz2
aports-480a758e59bbe099af01d90f36e117d4342a3a18.tar.xz
main/collectd: limit stack usage to reasonable amount
fixes a crash with musl as it defaults to smaller (sane) stack size
Diffstat (limited to 'main/collectd')
-rw-r--r--main/collectd/APKBUILD6
-rw-r--r--main/collectd/fix-argmax.patch21
2 files changed, 26 insertions, 1 deletions
diff --git a/main/collectd/APKBUILD b/main/collectd/APKBUILD
index ebd7ed7d5..551a2c962 100644
--- a/main/collectd/APKBUILD
+++ b/main/collectd/APKBUILD
@@ -1,7 +1,7 @@
# Maintainer: Natanael Copa <ncopa@alpinelinux.org>
pkgname=collectd
pkgver=5.4.1
-pkgrel=0
+pkgrel=1
pkgdesc="The system statistics collection daemon"
url="http://collectd.org"
arch="all"
@@ -19,6 +19,7 @@ subpackages="$pkgname-dev $pkgname-doc $pkgname-perl $pkgname-snmp
$pkgname-ascent"
source="http://collectd.org/files/collectd-$pkgver.tar.bz2
+ fix-argmax.patch
collectd.initd"
_builddir="$srcdir"/$pkgname-$pkgver
@@ -102,8 +103,11 @@ bind() { _plugin bind; }
ascent() { _plugin ascent; }
md5sums="6f56c71c96573a7f4f7fb3bfab185974 collectd-5.4.1.tar.bz2
+cd543f08b405c13b4734fa528cb6abef fix-argmax.patch
13a36ae2f92634b5619ab94224e1b77d collectd.initd"
sha256sums="75452129f271cb0aad28e57f12a49070618bbb7b6a9d64cf869e8766fa2f66e0 collectd-5.4.1.tar.bz2
+5bf48d30d7d1d0e37d6dc56a8189c1b7de21d483c138c0c54c356304aa89b223 fix-argmax.patch
418d43a5ab08a8097dd2ac5c1e839df64032e96c295f89fa3b8df08a08c3dc35 collectd.initd"
sha512sums="96289f52d3d1da55c862ae9ee2f57972682d7eab87387e97efa41fb5197599e097abd71aed2fe014e26af37c9ae98471e06dd181c725849976242642ce5c9492 collectd-5.4.1.tar.bz2
+c3f841874243a8236ac50e8fbaa419ff603e19ba5c7b8c2f0f5b2c03c7e301b6afd46224624a952cd1b3b86a6afeab61f509d674c04826dbcdb83461c47de3f4 fix-argmax.patch
fd3ba6914d1e95f255f43165f7d38405736799037d08300378678fa3a9c628b14b6a867d8e0367798cd488105547ef8eca4bef7e4b7de1814a12aa0072e4cbee collectd.initd"
diff --git a/main/collectd/fix-argmax.patch b/main/collectd/fix-argmax.patch
new file mode 100644
index 000000000..6477bd873
--- /dev/null
+++ b/main/collectd/fix-argmax.patch
@@ -0,0 +1,21 @@
+Bug reported upstream:
+https://github.com/collectd/collectd/issues/652
+
+Workaround patch by Timo Teräs <timo.teras@iki.fi>
+
+diff -ru collectd-5.4.1.orig/src/processes.c collectd-5.4.1/src/processes.c
+--- collectd-5.4.1.orig/src/processes.c 2014-01-26 10:09:14.000000000 -0200
++++ collectd-5.4.1/src/processes.c 2014-06-20 11:58:31.558125613 -0300
+@@ -128,9 +128,9 @@
+ # include <kstat.h>
+ #endif
+
+-#ifndef ARG_MAX
+-# define ARG_MAX 4096
+-#endif
++/* Force 4k ARG_MAX to make it work as stack allocated buffer */
++#undef ARG_MAX
++#define ARG_MAX 4096
+
+ typedef struct procstat_entry_s
+ {