From: Jan Kiszka <jan.kiszka@web.de>
To: linux-kernel@vger.kernel.org
Subject: NULL pointer bug in netpoll.c
Date: Sat, 19 Mar 2005 21:51:00 +0100 [thread overview]
Message-ID: <423C90B4.8030700@web.de> (raw)
[-- Attachment #1: Type: text/plain, Size: 202 bytes --]
Hi,
it seems that there is a gremlin sleeping in
net/core/netpoll.c:find_skb(). Even if no more buffers are available
through "skbs", "skb" is dereferenced anyway. The tiny patch should fix it.
Jan
[-- Attachment #2: netpoll.patch --]
[-- Type: text/plain, Size: 438 bytes --]
--- linux-2.6.11.4/net/core/netpoll.c.orig 2005-03-16 01:09:19.000000000 +0100
+++ linux-2.6.11.4/net/core/netpoll.c 2005-03-19 21:42:41.573018776 +0100
@@ -165,10 +165,11 @@ repeat:
if (!skb) {
spin_lock_irqsave(&skb_list_lock, flags);
skb = skbs;
- if (skb)
+ if (skb) {
skbs = skb->next;
- skb->next = NULL;
- nr_skbs--;
+ skb->next = NULL;
+ nr_skbs--;
+ }
spin_unlock_irqrestore(&skb_list_lock, flags);
}
reply other threads:[~2005-03-19 20:51 UTC|newest]
Thread overview: [no followups] expand[flat|nested] mbox.gz Atom feed
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=423C90B4.8030700@web.de \
--to=jan.kiszka@web.de \
--cc=linux-kernel@vger.kernel.org \
/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