From 851039cb9b2d1376eb56f5104801a52b14a1b18d Mon Sep 17 00:00:00 2001 From: Vadim Yanitskiy Date: Thu, 17 Jan 2019 14:52:35 +0700 Subject: trxcon/l1ctl.c: fix memleak triggered by unsupported messages Change-Id: I6e636afec8e45d7dc786f5f159cd5d7784d9a83b --- src/host/trxcon/l1ctl.c | 1 + 1 file changed, 1 insertion(+) diff --git a/src/host/trxcon/l1ctl.c b/src/host/trxcon/l1ctl.c index 0b6d75ac..2f1d720c 100644 --- a/src/host/trxcon/l1ctl.c +++ b/src/host/trxcon/l1ctl.c @@ -871,6 +871,7 @@ int l1ctl_rx_cb(struct l1ctl_link *l1l, struct msgb *msg) case L1CTL_SIM_REQ: LOGP(DL1C, LOGL_NOTICE, "Ignoring unsupported message " "(type=%u)\n", l1h->msg_type); + msgb_free(msg); return -ENOTSUP; default: LOGP(DL1C, LOGL_ERROR, "Unknown MSG type %u: %s\n", l1h->msg_type, -- cgit v1.2.3