aboutsummaryrefslogtreecommitdiffstats
path: root/drivers
diff options
context:
space:
mode:
authorGreg Kroah-Hartman <gregkh@suse.de>2011-11-27 14:34:34 -0500
committerGreg Kroah-Hartman <gregkh@suse.de>2011-11-27 14:36:10 -0500
commit06b446c8af5db5a98b2eaa30b513c79089ed254b (patch)
treeb1b2abec9775fc135d899b08351ac520a1197806 /drivers
parente384a41141949843899affcf51f4e6e646c1fe9f (diff)
Revert "Staging: comedi: integer overflow in do_insnlist_ioctl()"
This reverts commit e384a41141949843899affcf51f4e6e646c1fe9f. It's not the correct way to solve this issue. Acked-by: Dan Carpenter <dan.carpenter@oracle.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
Diffstat (limited to 'drivers')
-rw-r--r--drivers/staging/comedi/comedi_fops.c5
1 files changed, 0 insertions, 5 deletions
diff --git a/drivers/staging/comedi/comedi_fops.c b/drivers/staging/comedi/comedi_fops.c
index ed4853f194c4..ebdcecda3583 100644
--- a/drivers/staging/comedi/comedi_fops.c
+++ b/drivers/staging/comedi/comedi_fops.c
@@ -670,11 +670,6 @@ static int do_insnlist_ioctl(struct comedi_device *dev,
670 goto error; 670 goto error;
671 } 671 }
672 672
673 if (sizeof(struct comedi_insn) * insnlist.n_insns < insnlist.n_insns) {
674 ret = -EINVAL;
675 goto error;
676 }
677
678 insns = 673 insns =
679 kmalloc(sizeof(struct comedi_insn) * insnlist.n_insns, GFP_KERNEL); 674 kmalloc(sizeof(struct comedi_insn) * insnlist.n_insns, GFP_KERNEL);
680 if (!insns) { 675 if (!insns) {