summaryrefslogtreecommitdiffstats
path: root/net/ipv6/udp.c
diff options
context:
space:
mode:
authorDavid Ahern <dsa@cumulusnetworks.com>2016-08-23 21:06:33 -0700
committerDavid S. Miller <davem@davemloft.net>2016-08-23 23:12:27 -0700
commit5d77dca82839ef016a93ad7acd7058b14d967752 (patch)
tree6ce7ab03eddb29ebcca23e80de5018401b4b00e9 /net/ipv6/udp.c
parent5128b18522e143e634712ceef6a007333b8c7439 (diff)
downloadtalos-obmc-linux-5d77dca82839ef016a93ad7acd7058b14d967752.tar.gz
talos-obmc-linux-5d77dca82839ef016a93ad7acd7058b14d967752.zip
net: diag: support SOCK_DESTROY for UDP sockets
This implements SOCK_DESTROY for UDP sockets similar to what was done for TCP with commit c1e64e298b8ca ("net: diag: Support destroying TCP sockets.") A process with a UDP socket targeted for destroy is awakened and recvmsg fails with ECONNABORTED. Signed-off-by: David Ahern <dsa@cumulusnetworks.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'net/ipv6/udp.c')
-rw-r--r--net/ipv6/udp.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/net/ipv6/udp.c b/net/ipv6/udp.c
index 81e2f98b958d..16512cf06e73 100644
--- a/net/ipv6/udp.c
+++ b/net/ipv6/udp.c
@@ -1467,6 +1467,7 @@ struct proto udpv6_prot = {
.compat_getsockopt = compat_udpv6_getsockopt,
#endif
.clear_sk = udp_v6_clear_sk,
+ .diag_destroy = udp_abort,
};
static struct inet_protosw udpv6_protosw = {
OpenPOWER on IntegriCloud