# \[PATCH wpan 02/17\] net: ieee802154: fix memory leak when deliver monitor skbs

- From: Alexander Aring \<aahringo@redhat.com\>
- Date: 2021-02-28 15:20:30 
- List: netdev
- Page: https://ratatoskr.run/netdev/2021/02/11197574
- Thread: https://ratatoskr.run/netdev/2021/02/11197569/t.md

```text
This patch adds a missing consume_skb() when deliver a skb to upper
monitor interfaces of a wpan phy.

Reported-by: <redacted>
Signed-off-by: Alexander Aring <aahringo@redhat.com>
---
 net/mac802154/rx.c | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/net/mac802154/rx.c b/net/mac802154/rx.c
index b8ce84618a55..18abc1f49323 100644
--- a/net/mac802154/rx.c
+++ b/net/mac802154/rx.c
@@ -244,6 +244,8 @@ ieee802154_monitors_rx(struct ieee802154_local *local, struct sk_buff *skb)
 			sdata->dev->stats.rx_bytes += skb->len;
 		}
 	}
+
+	consume_skb(skb);
 }
 
 void ieee802154_rx(struct ieee802154_local *local, struct sk_buff *skb)
-- 
2.26.2

```
