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

Commit ad9547c0 authored by Dan Carpenter's avatar Dan Carpenter Committed by John W. Linville
Browse files

brcm80211: fmac: small memory leak on error



We should free "bus_if" here, it's a small leak but it makes the static
checkers happy.

Signed-off-by: default avatarDan Carpenter <dan.carpenter@oracle.com>
Signed-off-by: default avatarJohn W. Linville <linville@tuxdriver.com>
parent 7468722b
Loading
Loading
Loading
Loading
+3 −1
Original line number Diff line number Diff line
@@ -477,8 +477,10 @@ static int brcmf_ops_sdio_probe(struct sdio_func *func,
		if (!bus_if)
			return -ENOMEM;
		sdiodev = kzalloc(sizeof(struct brcmf_sdio_dev), GFP_KERNEL);
		if (!sdiodev)
		if (!sdiodev) {
			kfree(bus_if);
			return -ENOMEM;
		}
		sdiodev->dev = &func->card->dev;
		sdiodev->func[0] = func->card->sdio_func[0];
		sdiodev->func[1] = func;