diff options
author | Christian Engelmayer <[email protected]> | 2015-05-02 18:59:29 -0300 |
---|---|---|
committer | Mauro Carvalho Chehab <[email protected]> | 2015-05-12 13:26:30 -0300 |
commit | 59c0d7b1e46cbadca60f98f87906dd5f2d681764 (patch) | |
tree | 0a3bab3cd59d9e61c70bf8eee78546367c812955 | |
parent | 699dcffc5244388a38f6323afc15ed3833c1ad96 (diff) |
[media] mn88472: Fix possible leak in mn88472_init()
Commit 307e95c92257 ("[media] mn88472: implement firmware parity check")
introduced the usage of exit paths that do not free the already allocated
firmware data in case the parity handling fails. Go through the correct
exit paths. Detected by Coverity CID 1295989.
Signed-off-by: Christian Engelmayer <[email protected]>
Acked-by: Benjamin Larsson <[email protected]>
Signed-off-by: Antti Palosaari <[email protected]>
Signed-off-by: Mauro Carvalho Chehab <[email protected]>
-rw-r--r-- | drivers/staging/media/mn88472/mn88472.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/drivers/staging/media/mn88472/mn88472.c b/drivers/staging/media/mn88472/mn88472.c index a4cfcf57c99c..6863c431c648 100644 --- a/drivers/staging/media/mn88472/mn88472.c +++ b/drivers/staging/media/mn88472/mn88472.c @@ -344,12 +344,12 @@ static int mn88472_init(struct dvb_frontend *fe) if (ret) { dev_err(&client->dev, "parity reg read failed=%d\n", ret); - goto err; + goto firmware_release; } if (tmp & 0x10) { dev_err(&client->dev, "firmware parity check failed=0x%x\n", tmp); - goto err; + goto firmware_release; } dev_err(&client->dev, "firmware parity check succeeded=0x%x\n", tmp); |