Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 21c75ad6 authored by YueHaibing's avatar YueHaibing Committed by Greg Kroah-Hartman
Browse files

parport_cs: Fix memory leak in parport_config



parport_probe() alloc parport device 'info',
but while parport_config failed it does not free it.

Signed-off-by: default avatarYueHaibing <yuehaibing@huawei.com>
Reviewed-by: default avatarMukesh Ojha <mojha@codeaurora.org>
Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
parent 8c2ffd91
Loading
Loading
Loading
Loading
+3 −2
Original line number Diff line number Diff line
@@ -159,6 +159,7 @@ static int parport_config(struct pcmcia_device *link)

failed:
	parport_cs_release(link);
	kfree(link->priv);
	return -ENODEV;
} /* parport_config */