aboutsummaryrefslogtreecommitdiffstats
path: root/main/pmacct/stacksize.patch
diff options
context:
space:
mode:
authorLeonardo Arena <rnalrd@alpinelinux.org>2015-12-10 08:39:14 +0000
committerLeonardo Arena <rnalrd@alpinelinux.org>2015-12-10 08:39:19 +0000
commitd49679d4f291dc64963aaa5f800a33e0edbb6f10 (patch)
treeaae405f41af6c60a6158ed6e5079495a65519161 /main/pmacct/stacksize.patch
parent93c98bfa2686f63820cad734ea13e2e8471c2ca4 (diff)
downloadaports-d49679d4f291dc64963aaa5f800a33e0edbb6f10.tar.bz2
aports-d49679d4f291dc64963aaa5f800a33e0edbb6f10.tar.xz
main/pmacct: upgrade to 1.5.2
Diffstat (limited to 'main/pmacct/stacksize.patch')
-rw-r--r--main/pmacct/stacksize.patch39
1 files changed, 0 insertions, 39 deletions
diff --git a/main/pmacct/stacksize.patch b/main/pmacct/stacksize.patch
deleted file mode 100644
index 96d6b00c56..0000000000
--- a/main/pmacct/stacksize.patch
+++ /dev/null
@@ -1,39 +0,0 @@
---- ./src/thread_pool.c.orig 2015-06-23 11:22:18.408373704 -0200
-+++ ./src/thread_pool.c 2015-06-23 11:31:55.926972746 -0200
-@@ -42,12 +42,15 @@
- #define pthread_mutex_unlock debug_pthread_mutex_unlock
- #endif
-
-+/* set default stack size to 1MB */
-+#define PMACCT_STACKSIZE 1024*1024
-
- thread_pool_t *allocate_thread_pool(int count)
- {
- int i, rc;
- thread_pool_t *pool;
- thread_pool_item_t *worker;
-+ pthread_attr_t attr, *attrptr = NULL;
-
- // Allocate pool
- pool = malloc(sizeof(thread_pool_t));
-@@ -88,7 +91,19 @@
-
- /* Create the thread */
- worker->thread = malloc(sizeof(pthread_t));
-- rc = pthread_create(worker->thread, NULL, thread_runner, worker);
-+ rc = pthread_attr_init(&attr);
-+ if (rc) {
-+ printf("ERROR: pthread_attr_init failed: %s\n", strerror(rc));
-+ } else {
-+ rc = pthread_attr_setstacksize(&attr, PMACCT_STACKSIZE);
-+ if (rc) {
-+ printf("ERROR: pthread_attr_setstack failed: %s\n", strerror(rc));
-+ } else {
-+ attrptr=&attr;
-+ }
-+ }
-+
-+ rc = pthread_create(worker->thread, attrptr, thread_runner, worker);
-
- if (rc) {
- printf("ERROR: thread creation failed: %s\n", strerror(rc));