Another fix to be able to change values into the /dev/container/*_shares
files.
By default:
echo "res=numtasks,min_shares=50" | cat > /dev/container/numtasks_shares
cat: write error: Invalid argument
pl
kernel/res_group/rgcs.c | 7 ++++---
1 files changed, 4 insertions(+), 3 deletions(-)
--- linux-2618+container/kernel/res_group/rgcs.c.old 2006-10-10
07:25:09.000000000 +0200
+++ linux-2618+container/kernel/res_group/rgcs.c 2006-10-11
12:27:54.000000000 +0200
@@ -230,16 +230,17 @@ ssize_t res_group_file_write(struct cont
ssize_t retval;
int filetype = cft->private;
- if (nbytes >= PAGE_SIZE)
+ if (nbytes > PAGE_SIZE)
return -E2BIG;
- buf = kmalloc(nbytes + 1, GFP_USER);
+ buf = kmalloc(nbytes, GFP_USER);
if (!buf) return -ENOMEM;
if (copy_from_user(buf, userbuf, nbytes)) {
retval = -EFAULT;
goto out1;
}
- buf[nbytes] = 0; /* nul-terminate */
+ buf[nbytes - 1] = 0; /* nul-terminate */
+ buf[nbytes] = 0;
container_manage_lock();
-------------------------------------------------------------------------
Using Tomcat but need to do more? Need to support web services, security?
Get stuff done quickly with pre-integrated technology to make your job easier
Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo
http://sel.as-us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&dat=121642
_______________________________________________
ckrm-tech mailing list
https://lists.sourceforge.net/lists/listinfo/ckrm-tech