Initial INC MR3 commit with EVO/BRAVO included and majority of the compile warnings ...
/net/ipv4/netfilter/ipt_CLUSTERIP.c
blob:2e4f98b85524ab6fa7baf8c945dc2017e90fcfff -> blob:edd820536f29925b80f0565d0494660876ee5861
--- net/ipv4/netfilter/ipt_CLUSTERIP.c
+++ net/ipv4/netfilter/ipt_CLUSTERIP.c
@@ -666,8 +666,11 @@ static ssize_t clusterip_proc_write(stru
struct clusterip_config *c = pde->data;
unsigned long nodenum;
- if (copy_from_user(buffer, input, PROC_WRITELEN))
+ if (size > PROC_WRITELEN)
+ return -EIO;
+ if (copy_from_user(buffer, input, size))
return -EFAULT;
+ buffer[size] = 0;
if (*buffer == '+') {
nodenum = simple_strtoul(buffer+1, NULL, 10);