From: "David S. Miller" <davem@redhat.com>
To: Krishna Kumar <krkumar@us.ibm.com>
Cc: netdev@oss.sgi.com, krkumar@us.ibm.com
Subject: Re: [PATCH] Uninitialized dst in ip6_dst_lookup
Date: Wed, 21 Jan 2004 22:14:21 -0800 [thread overview]
Message-ID: <20040121221421.11399ba3.davem@redhat.com> (raw)
In-Reply-To: <Pine.LNX.4.44.0401201115500.23508-100000@linux-udp15191261uds.beaverton.ibm.com>
On Tue, 20 Jan 2004 11:46:02 -0800 (PST)
Krishna Kumar <krkumar@us.ibm.com> wrote:
> ip6_dst_lookup() is supposed to fill in the *dst, hence it must not
> dereference *dst until it allocates it. However if the passed sk is
> NULL and *dst is not set by the caller, the following code will
> dereference uninitialized memory :
>
> if (*dst == NULL)
> *dst = ip6_route_output(sk, fl); >>>>> will not execute
> if ((err = (*dst)->error)) >>>>> dereference bad stack address.
> goto out_err_release;
>
> I am suggesting moving the responsibility of ensuring a good *dst from the
> callers to ip6_dst_lookup().
I agree, patch applied.
Thanks.
next prev parent reply other threads:[~2004-01-22 6:14 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
[not found] <OFB49626C9.096C6A6C-ON87256E20.006D3112@us.ibm.com>
2004-01-19 19:49 ` [TEST_PATCH]Re: Fw: Oops in register_proc_table (2.6.1-mm4) Krishna Kumar
2004-01-19 23:51 ` Thomas Schlichter
2004-01-20 0:06 ` [PATCH] " Krishna Kumar
2004-01-20 5:11 ` David S. Miller
2004-01-20 19:46 ` [PATCH] Uninitialized dst in ip6_dst_lookup Krishna Kumar
2004-01-22 6:14 ` David S. Miller [this message]
2004-02-05 1:41 ` [PATCH] bug in xfrm_lookup [bugzilla 2017] Krishna Kumar
2004-02-05 7:12 ` David S. Miller
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=20040121221421.11399ba3.davem@redhat.com \
--to=davem@redhat.com \
--cc=krkumar@us.ibm.com \
--cc=netdev@oss.sgi.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;
as well as URLs for NNTP newsgroup(s).