staging: comedi: ni_mio_common: ni_gpct_device_destroy() can handle a NULL pointer
Remove the unnecessary NULL pointer check. Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
This commit is contained in:
parent
bed05b6c34
commit
99307a69bf
@ -5675,8 +5675,6 @@ static void mio_common_detach(struct comedi_device *dev)
|
||||
{
|
||||
struct ni_private *devpriv = dev->private;
|
||||
|
||||
if (devpriv) {
|
||||
if (devpriv->counter_dev)
|
||||
ni_gpct_device_destroy(devpriv->counter_dev);
|
||||
}
|
||||
if (devpriv)
|
||||
ni_gpct_device_destroy(devpriv->counter_dev);
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user