From: Wang Liang <wangliang74@huawei.com>
To: <syzbot+d7abc36bbbb6d7d40b58@syzkaller.appspotmail.com>
Cc: <davem@davemloft.net>, <edumazet@google.com>, <horms@kernel.org>,
<kuba@kernel.org>, <linux-hams@vger.kernel.org>,
<linux-kernel@vger.kernel.org>, <netdev@vger.kernel.org>,
<pabeni@redhat.com>, <syzkaller-bugs@googlegroups.com>,
<yuehaibing@huawei.com>, <zhangchangzhong@huawei.com>,
<wangliang74@huawei.com>
Subject: Re: [syzbot] [hams?] memory leak in nr_sendmsg
Date: Sat, 29 Nov 2025 09:47:43 +0800 [thread overview]
Message-ID: <20251129014743.1368452-1-wangliang74@huawei.com> (raw)
In-Reply-To: <692a2462.a70a0220.d98e3.0152.GAE@google.com>
#syz test
diff --git a/net/netrom/nr_out.c b/net/netrom/nr_out.c
index 5e531394a724..2b3cbceb0b52 100644
--- a/net/netrom/nr_out.c
+++ b/net/netrom/nr_out.c
@@ -43,8 +43,10 @@ void nr_output(struct sock *sk, struct sk_buff *skb)
frontlen = skb_headroom(skb);
while (skb->len > 0) {
- if ((skbn = sock_alloc_send_skb(sk, frontlen + NR_MAX_PACKET_SIZE, 0, &err)) == NULL)
+ if ((skbn = sock_alloc_send_skb(sk, frontlen + NR_MAX_PACKET_SIZE, 0, &err)) == NULL) {
+ kfree_skb(skb);
return;
+ }
skb_reserve(skbn, frontlen);
--
2.34.1
next prev parent reply other threads:[~2025-11-29 1:26 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2025-11-28 22:38 [syzbot] [hams?] memory leak in nr_sendmsg syzbot
2025-11-29 1:47 ` Wang Liang [this message]
2025-11-29 2:36 ` syzbot
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20251129014743.1368452-1-wangliang74@huawei.com \
--to=wangliang74@huawei.com \
--cc=davem@davemloft.net \
--cc=edumazet@google.com \
--cc=horms@kernel.org \
--cc=kuba@kernel.org \
--cc=linux-hams@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=netdev@vger.kernel.org \
--cc=pabeni@redhat.com \
--cc=syzbot+d7abc36bbbb6d7d40b58@syzkaller.appspotmail.com \
--cc=syzkaller-bugs@googlegroups.com \
--cc=yuehaibing@huawei.com \
--cc=zhangchangzhong@huawei.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox