diff options
author | H Hartley Sweeten <hartleys@visionengravers.com> | 2013-01-25 15:02:06 -0700 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@linuxfoundation.org> | 2013-01-29 23:06:41 -0500 |
commit | c65c64d0f0b269b1239fdce253fd4717281cc98d (patch) | |
tree | 25d60f75b75daa1097778dbbcf3a649ae231354e /tools/perf/scripts/python/sctop.py | |
parent | e23fe9a1bf80eee77d4cc97504bcec0c40ed973d (diff) |
staging: comedi: quatech_daqp_cs: fix possible memory dereference issue
In daqp_attach(), the first options value passed in the comedi_devconfig
is used as an index to the private dev_table[] in this driver. This table
is used to pass the pcmcia_device to the comedi_driver.
Fix the code so that the index is checked before the table is accessed
so that we don't get a possible memory dereference BUG.
Change the error returned to the comedi core from -EIO to -ENODEV.
Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com>
Cc: Ian Abbott <abbotti@mev.co.uk>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'tools/perf/scripts/python/sctop.py')
0 files changed, 0 insertions, 0 deletions