--- kernel/cpuset.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) Index: linux-2.6/kernel/cpuset.c =================================================================== --- linux-2.6.orig/kernel/cpuset.c 2007-06-01 13:41:24.000000000 -0700 +++ linux-2.6/kernel/cpuset.c 2007-06-01 13:42:08.000000000 -0700 @@ -1741,7 +1741,7 @@ static int cpuset_tasks_open(struct inod * show up until sometime later on. */ npids = atomic_read(&cs->count); - pidarray = kmalloc(npids * sizeof(pid_t), GFP_KERNEL); + pidarray = kmalloc(max(1, npids) * sizeof(pid_t), GFP_KERNEL); if (!pidarray) goto err1;