summaryrefslogtreecommitdiff
path: root/package/busybox/busybox-1.10.1-taskset.patch
diff options
context:
space:
mode:
authorPeter Korsgaard <jacmet@sunsite.dk>2008-04-29 06:53:55 +0000
committerPeter Korsgaard <jacmet@sunsite.dk>2008-04-29 06:53:55 +0000
commit8fdb0e25e683b26990cb9d9a4c14e5422d7a3834 (patch)
treefac77f1532268b3eb132eb9ff094d13e71ed1231 /package/busybox/busybox-1.10.1-taskset.patch
parent509fe4a6de108464aed16e7b49aa44e779c5e11a (diff)
busybox: 1.10.1 patches
Diffstat (limited to 'package/busybox/busybox-1.10.1-taskset.patch')
-rw-r--r--package/busybox/busybox-1.10.1-taskset.patch14
1 files changed, 14 insertions, 0 deletions
diff --git a/package/busybox/busybox-1.10.1-taskset.patch b/package/busybox/busybox-1.10.1-taskset.patch
new file mode 100644
index 000000000..0860586b7
--- /dev/null
+++ b/package/busybox/busybox-1.10.1-taskset.patch
@@ -0,0 +1,14 @@
+--- busybox-1.10.1/miscutils/taskset.c Sat Apr 19 06:03:13 2008
++++ busybox-1.10.1-taskset/miscutils/taskset.c Fri Apr 25 18:58:53 2008
+@@ -94,8 +94,10 @@
+ unsigned i;
+ /* Do not allow zero mask: */
+ unsigned long long m = xstrtoull_range(aff, 0, 1, ULLONG_MAX);
++ enum { CNT_BIT = CPU_SETSIZE < sizeof(m)*8 ? CPU_SETSIZE : sizeof(m)*8 };
++
+ CPU_ZERO(&mask);
+- for (i = 0; i < CPU_SETSIZE; i++) {
++ for (i = 0; i < CNT_BIT; i++) {
+ unsigned long long bit = (1ULL << i);
+ if (bit & m)
+ CPU_SET(i, &mask);