Skip to content
Commit d19319af authored by Takeshi Yoshimura's avatar Takeshi Yoshimura Committed by Dominik Brodowski
Browse files

pcmcia: Fix resource leaks in yenta_probe() and _close()



There are some resource leaks in yenta_probe() and _close(). I fixed
the following issues with some code cleanups. Thanks to Dominik's
suggestions.

On the error path in yenta_probe():
- a requested irq is not released
- yenta_free_resources() and pci_set_drvdata(dev, NULL) are not called

In yenta_close():
- kfree(sock) is not called
- sock->base is always set to non-NULL when yenta_close() is called,
  therefore the check in yenta_close() is not necessary.

Signed-off-by: default avatarTakeshi Yoshimura <yos@sslab.ics.keio.ac.jp>
Signed-off-by: default avatarDominik Brodowski <linux@dominikbrodowski.net>
parent 2fb22a80
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment