vserver 2.0 rc7
[linux-2.6.git] / net / bridge / br_ioctl.c
index 363c73f..b8ce14b 100644 (file)
@@ -324,6 +324,8 @@ static int old_deviceless(void __user *uarg)
                int *indices;
                int ret = 0;
 
+               if (args[2] >= 2048)
+                       return -ENOMEM;
                indices = kmalloc(args[2]*sizeof(int), GFP_KERNEL);
                if (indices == NULL)
                        return -ENOMEM;