[PATCH] [UDPv6] Possible dst leak in udpv6_sendmsg.

!MAILaRCHIVE_VOTE_RePLACE
Previous message: [thread] [date] [author]
Next message: [thread] [date] [author]
To: <yoshfuji@...>
Cc: <davem@...>, <netdev@...>, <kaber@...>, Denis V. Lunev <den@...>
Date: Tuesday, June 3, 2008 - 7:08 am

ip6_sk_dst_lookup returns held dst entry. It should be released on all paths
beyond this point. Add missed release when up->pending is set.

Signed-off-by: Denis V. Lunev <den@openvz.org>
---
 net/ipv6/udp.c |    1 +
 1 files changed, 1 insertions(+), 0 deletions(-)

diff --git a/net/ipv6/udp.c b/net/ipv6/udp.c
index 1fd784f..3235528 100644
--- a/net/ipv6/udp.c
+++ b/net/ipv6/udp.c
@@ -813,6 +813,7 @@ back_from_confirm:
 		/* The socket is already corked while preparing it. */
 		/* ... which is an evident application bug. --ANK */
 		release_sock(sk);
+		dst_release(dst);
 
 		LIMIT_NETDEBUG(KERN_DEBUG "udp cork app bug 2\n");
 		err = -EINVAL;
-- 
1.5.3.rc5

--
To unsubscribe from this list: send the line "unsubscribe netdev" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Previous message: [thread] [date] [author]
Next message: [thread] [date] [author]

Messages in current thread:
[PATCH] [UDPv6] Possible dst leak in udpv6_sendmsg., Denis V. Lunev, (Tue Jun 3, 7:08 am)
Re: [PATCH] [UDPv6] Possible dst leak in udpv6_sendmsg., YOSHIFUJI Hideaki / , (Tue Jun 3, 7:35 am)
Re: [PATCH] [UDPv6] Possible dst leak in udpv6_sendmsg., Denis V. Lunev, (Tue Jun 3, 7:50 am)
Re: [PATCH] [UDPv6] Possible dst leak in udpv6_sendmsg., YOSHIFUJI Hideaki / , (Tue Jun 3, 12:26 pm)
Re: [PATCH] [UDPv6] Possible dst leak in udpv6_sendmsg., Denis V. Lunev, (Tue Jun 3, 12:34 pm)
Re: [PATCH] [UDPv6] Possible dst leak in udpv6_sendmsg., YOSHIFUJI Hideaki / , (Tue Jun 3, 12:36 pm)