Skip to contentSkip to conversation

staging: comedi: remove an unneeded variable

PATCH In review Dan Carpenter 2 participants 2 messages Mar 31, 2014

Subsystems (2)
lore
Share & tools
lore
#0 lore raw

PATCH 1/1 staging: comedi: remove an unneeded variable

"chanlist" was left over, we don't need it any more.

drivers/staging/comedi/comedi_fops.c +0 -3
index ea6dc36..1e91161 100644
@@ -1597,7 +1597,6 @@ static int do_cmdtest_ioctl(struct comedi_device *dev,
 {
 	struct comedi_cmd cmd;
 	struct comedi_subdevice *s;
-	unsigned int *chanlist = NULL;
 	unsigned int __user *user_chanlist;
 	int ret;
 
@@ -1626,8 +1625,6 @@ static int do_cmdtest_ioctl(struct comedi_device *dev,
 		ret = -EFAULT;
 	}
 
-	kfree(chanlist);
-
 	return ret;
 }
 
Reviewed-by on v1 1/1
#1 lore raw
Quoted 18 lines · Dan Carpenter

"chanlist" was left over, we don't need it any more.

drivers/staging/comedi/comedi_fops.c +0 -1
index ea6dc36..1e91161 100644
@@ -1597,7 +1597,6 @@ static int do_cmdtest_ioctl(struct comedi_device *dev,
  {
  	struct comedi_cmd cmd;
  	struct comedi_subdevice *s;
-	unsigned int *chanlist = NULL;
  	unsigned int __user *user_chanlist;
  	int ret;
 

drivers/staging/comedi/comedi_fops.c static int do_cmdtest_ioctl(struct comedi_device *dev, · line 1630

Quoted 8 lines
drivers/staging/comedi/comedi_fops.c +0 -2
@@ -1626,8 +1625,6 @@ static int do_cmdtest_ioctl(struct comedi_device *dev,
  		ret = -EFAULT;
  	}
 
-	kfree(chanlist);
-
  	return ret;
  }
 
Signature · 2 lines
-=( Ian Abbott @ MEV Ltd.    E-mail: <[email protected]>        )=-
-=( Tel: +44 (0)161 477 1898   FAX: +44 (0)161 718 3587         )=-