[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-Id: <20110828.171154.1746224796788156557.davem@davemloft.net>
Date: Sun, 28 Aug 2011 17:11:54 -0400 (EDT)
From: David Miller <davem@...emloft.net>
To: zenczykowski@...il.com
Cc: maze@...gle.com, netdev@...r.kernel.org, yoshfuji@...ux-ipv6.org,
ek@...gle.com, lorenzo@...gle.com
Subject: Re: [PATCH] net: relax PKTINFO non local ipv6 udp xmit check
From: Maciej Żenczykowski <zenczykowski@...il.com>
Date: Fri, 26 Aug 2011 14:56:28 -0700
> diff --git a/net/ipv6/ip6_flowlabel.c b/net/ipv6/ip6_flowlabel.c
> index f3caf1b..a896987 100644
> --- a/net/ipv6/ip6_flowlabel.c
> +++ b/net/ipv6/ip6_flowlabel.c
> @@ -360,7 +360,7 @@ fl_create(struct net *net, struct in6_flowlabel_req *freq, char __user *optval,
> msg.msg_control = (void*)(fl->opt+1);
> memset(&flowi6, 0, sizeof(flowi6));
>
> - err = datagram_send_ctl(net, &msg, &flowi6, fl->opt, &junk,
> + err = datagram_send_ctl(net, NULL, &msg, &flowi6, fl->opt, &junk,
> &junk, &junk);
> if (err)
> goto done;
There is a socket associated with this fl_create() request, please
pass it into fl_create() from it's caller, and thus down into
datagram_send_ctl(), instead of just passing NULL.
Then, since a valid sk is always passed in, you can elide the NULL
check on 'sk' down at the bottom of these code paths.
Thanks.
--
To unsubscribe from this list: send the line "unsubscribe netdev" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Powered by blists - more mailing lists