summaryrefslogtreecommitdiffstats
path: root/drivers
diff options
context:
space:
mode:
authorNicolas Kaiser <nikai@nikai.net>2010-11-13 19:46:50 +0100
committerGreg Kroah-Hartman <gregkh@suse.de>2010-11-16 21:25:52 +0100
commit61838261edaf621d1e8ee4ea9d7c052f7d783ca4 (patch)
tree66044dcc8e633cecb55e78b3e2c2182edd7c00c4 /drivers
parentStaging: quickstart: free after input_unregister_device() (diff)
downloadlinux-61838261edaf621d1e8ee4ea9d7c052f7d783ca4.tar.xz
linux-61838261edaf621d1e8ee4ea9d7c052f7d783ca4.zip
staging: comedi: fix memory leak
Instead of freeing outBuffer, inBuffer gets freed twice. Signed-off-by: Nicolas Kaiser <nikai@nikai.net> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
Diffstat (limited to 'drivers')
-rw-r--r--drivers/staging/comedi/drivers/usbdux.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/drivers/staging/comedi/drivers/usbdux.c b/drivers/staging/comedi/drivers/usbdux.c
index 1f177a67ff11..de784ff08caa 100644
--- a/drivers/staging/comedi/drivers/usbdux.c
+++ b/drivers/staging/comedi/drivers/usbdux.c
@@ -2295,8 +2295,8 @@ static void tidy_up(struct usbduxsub *usbduxsub_tmp)
usbduxsub_tmp->inBuffer = NULL;
kfree(usbduxsub_tmp->insnBuffer);
usbduxsub_tmp->insnBuffer = NULL;
- kfree(usbduxsub_tmp->inBuffer);
- usbduxsub_tmp->inBuffer = NULL;
+ kfree(usbduxsub_tmp->outBuffer);
+ usbduxsub_tmp->outBuffer = NULL;
kfree(usbduxsub_tmp->dac_commands);
usbduxsub_tmp->dac_commands = NULL;
kfree(usbduxsub_tmp->dux_commands);