aboutsummaryrefslogtreecommitdiffstats
path: root/main/bash/fix-jobs.patch
diff options
context:
space:
mode:
authorNatanael Copa <ncopa@alpinelinux.org>2018-02-07 19:00:58 +0000
committerNatanael Copa <ncopa@alpinelinux.org>2018-02-07 19:04:45 +0000
commit6c1881db229de5cdc49bc974b7b99badc3e187aa (patch)
tree2b38e7c5c6adc21cd8067dfd9eea665484ec9ae3 /main/bash/fix-jobs.patch
parent8756c780bda76051ece619cab28acf83c63a920f (diff)
downloadaports-6c1881db229de5cdc49bc974b7b99badc3e187aa.tar.gz
aports-6c1881db229de5cdc49bc974b7b99badc3e187aa.tar.bz2
aports-6c1881db229de5cdc49bc974b7b99badc3e187aa.tar.xz
main/bash: fix jobs again
previous fix didnt solve the problem for 32 bit architectures. We fix it by capping childmax to 8192. ref #8447
Diffstat (limited to 'main/bash/fix-jobs.patch')
-rw-r--r--main/bash/fix-jobs.patch29
1 files changed, 21 insertions, 8 deletions
diff --git a/main/bash/fix-jobs.patch b/main/bash/fix-jobs.patch
index c01db4e19f..ddb9d4659a 100644
--- a/main/bash/fix-jobs.patch
+++ b/main/bash/fix-jobs.patch
@@ -1,13 +1,26 @@
diff --git a/jobs.c b/jobs.c
-index fc96603..d203db2 100644
+index cef3c79..bf99266 100644
--- a/jobs.c
+++ b/jobs.c
-@@ -765,7 +765,7 @@ bgp_resize ()
- else
- nsize = bgpids.nalloc;
+@@ -4166,10 +4166,8 @@ initialize_job_control (force)
+ if (js.c_childmax < 0)
+ js.c_childmax = DEFAULT_CHILD_MAX;
-- while (nsize < js.c_childmax)
-+ while (nsize < (ps_index_t)js.c_childmax)
- nsize *= 2;
+-#if 0
+ if (js.c_childmax > MAX_CHILD_MAX)
+ js.c_childmax = MAX_CHILD_MAX;
+-#endif
- if (bgpids.nalloc < js.c_childmax)
+ return job_control;
+ }
+@@ -4547,10 +4545,8 @@ mark_dead_jobs_as_notified (force)
+ if (js.c_childmax < 0)
+ js.c_childmax = DEFAULT_CHILD_MAX;
+
+-#if 0
+ if (js.c_childmax > MAX_CHILD_MAX)
+ js.c_childmax = MAX_CHILD_MAX;
+-#endif
+
+ /* Don't do anything if the number of dead processes is less than CHILD_MAX
+ and we're not forcing a cleanup. */