From 9704df968058b075b915ca5610537b4a5ea85c08 Mon Sep 17 00:00:00 2001 From: Mikio Hara Date: Sun, 27 Apr 2014 22:30:08 +0900 Subject: [PATCH] go.net/ipv6: add support for dragonfly Update golang/go#7174 LGTM=iant R=golang-codereviews, iant CC=golang-codereviews https://golang.org/cl/91770049 --- ipv6/control_rfc3542_stub.go | 2 +- ipv6/control_rfc3542_unix.go | 2 +- ipv6/dgramopt_posix.go | 2 +- ipv6/dgramopt_stub.go | 2 +- ipv6/genericopt_posix.go | 2 +- ipv6/genericopt_stub.go | 2 +- ipv6/helper_stub.go | 2 +- ipv6/helper_unix.go | 2 +- ipv6/icmp_bsd.go | 2 +- ipv6/icmp_stub.go | 2 +- ipv6/icmp_test.go | 4 ++-- ipv6/multicast_test.go | 4 ++-- ipv6/multicastlistener_test.go | 8 ++++---- ipv6/multicastsockopt_test.go | 2 +- ipv6/readwrite_test.go | 2 +- ipv6/sockopt_rfc3493_bsd.go | 2 +- ipv6/sockopt_rfc3493_unix.go | 2 +- ipv6/sockopt_rfc3542_stub.go | 2 +- ipv6/sockopt_rfc3542_unix.go | 2 +- ipv6/sockopt_test.go | 8 ++++---- ipv6/sys_bsd.go | 2 +- ipv6/sys_unix.go | 2 +- ipv6/syscall_unix.go | 2 +- ipv6/unicast_test.go | 4 ++-- ipv6/unicastsockopt_test.go | 4 ++-- 25 files changed, 35 insertions(+), 35 deletions(-) diff --git a/ipv6/control_rfc3542_stub.go b/ipv6/control_rfc3542_stub.go index 4419bf51..214142e2 100644 --- a/ipv6/control_rfc3542_stub.go +++ b/ipv6/control_rfc3542_stub.go @@ -2,7 +2,7 @@ // Use of this source code is governed by a BSD-style // license that can be found in the LICENSE file. -// +build dragonfly plan9 solaris +// +build plan9 solaris package ipv6 diff --git a/ipv6/control_rfc3542_unix.go b/ipv6/control_rfc3542_unix.go index 882a77be..0f5149fa 100644 --- a/ipv6/control_rfc3542_unix.go +++ b/ipv6/control_rfc3542_unix.go @@ -2,7 +2,7 @@ // Use of this source code is governed by a BSD-style // license that can be found in the LICENSE file. -// +build freebsd linux netbsd openbsd +// +build dragonfly freebsd linux netbsd openbsd package ipv6 diff --git a/ipv6/dgramopt_posix.go b/ipv6/dgramopt_posix.go index c52f48da..d12d123a 100644 --- a/ipv6/dgramopt_posix.go +++ b/ipv6/dgramopt_posix.go @@ -2,7 +2,7 @@ // Use of this source code is governed by a BSD-style // license that can be found in the LICENSE file. -// +build darwin freebsd linux netbsd openbsd windows +// +build darwin dragonfly freebsd linux netbsd openbsd windows package ipv6 diff --git a/ipv6/dgramopt_stub.go b/ipv6/dgramopt_stub.go index 9c760dfc..6d73fcd6 100644 --- a/ipv6/dgramopt_stub.go +++ b/ipv6/dgramopt_stub.go @@ -2,7 +2,7 @@ // Use of this source code is governed by a BSD-style // license that can be found in the LICENSE file. -// +build dragonfly plan9 solaris +// +build plan9 solaris package ipv6 diff --git a/ipv6/genericopt_posix.go b/ipv6/genericopt_posix.go index a3a9af9a..7b8ae8c1 100644 --- a/ipv6/genericopt_posix.go +++ b/ipv6/genericopt_posix.go @@ -2,7 +2,7 @@ // Use of this source code is governed by a BSD-style // license that can be found in the LICENSE file. -// +build darwin freebsd linux netbsd openbsd windows +// +build darwin dragonfly freebsd linux netbsd openbsd windows package ipv6 diff --git a/ipv6/genericopt_stub.go b/ipv6/genericopt_stub.go index 1b421959..1f8df1ba 100644 --- a/ipv6/genericopt_stub.go +++ b/ipv6/genericopt_stub.go @@ -2,7 +2,7 @@ // Use of this source code is governed by a BSD-style // license that can be found in the LICENSE file. -// +build dragonfly plan9 solaris +// +build plan9 solaris package ipv6 diff --git a/ipv6/helper_stub.go b/ipv6/helper_stub.go index 0b5b35a3..d6e643b3 100644 --- a/ipv6/helper_stub.go +++ b/ipv6/helper_stub.go @@ -2,7 +2,7 @@ // Use of this source code is governed by a BSD-style // license that can be found in the LICENSE file. -// +build dragonfly plan9 solaris +// +build plan9 solaris package ipv6 diff --git a/ipv6/helper_unix.go b/ipv6/helper_unix.go index 6ad8db45..92868ed2 100644 --- a/ipv6/helper_unix.go +++ b/ipv6/helper_unix.go @@ -2,7 +2,7 @@ // Use of this source code is governed by a BSD-style // license that can be found in the LICENSE file. -// +build darwin freebsd linux netbsd openbsd +// +build darwin dragonfly freebsd linux netbsd openbsd package ipv6 diff --git a/ipv6/icmp_bsd.go b/ipv6/icmp_bsd.go index b92e0d9e..92d3d62c 100644 --- a/ipv6/icmp_bsd.go +++ b/ipv6/icmp_bsd.go @@ -2,7 +2,7 @@ // Use of this source code is governed by a BSD-style // license that can be found in the LICENSE file. -// +build darwin freebsd netbsd openbsd +// +build darwin dragonfly freebsd netbsd openbsd package ipv6 diff --git a/ipv6/icmp_stub.go b/ipv6/icmp_stub.go index 312269cf..177e9cba 100644 --- a/ipv6/icmp_stub.go +++ b/ipv6/icmp_stub.go @@ -2,7 +2,7 @@ // Use of this source code is governed by a BSD-style // license that can be found in the LICENSE file. -// +build dragonfly plan9 solaris +// +build plan9 solaris package ipv6 diff --git a/ipv6/icmp_test.go b/ipv6/icmp_test.go index 09145134..8ae50cc6 100644 --- a/ipv6/icmp_test.go +++ b/ipv6/icmp_test.go @@ -34,7 +34,7 @@ func TestICMPString(t *testing.T) { func TestICMPFilter(t *testing.T) { switch runtime.GOOS { - case "dragonfly", "plan9", "solaris", "windows": + case "plan9", "solaris", "windows": t.Skipf("not supported on %q", runtime.GOOS) } @@ -67,7 +67,7 @@ func TestICMPFilter(t *testing.T) { func TestSetICMPFilter(t *testing.T) { switch runtime.GOOS { - case "dragonfly", "plan9", "solaris", "windows": + case "plan9", "solaris", "windows": t.Skipf("not supported on %q", runtime.GOOS) } if !supportsIPv6 { diff --git a/ipv6/multicast_test.go b/ipv6/multicast_test.go index 89c37a8a..120ebdba 100644 --- a/ipv6/multicast_test.go +++ b/ipv6/multicast_test.go @@ -19,7 +19,7 @@ func TestPacketConnReadWriteMulticastUDP(t *testing.T) { case "freebsd": // due to a bug on loopback marking // See http://www.freebsd.org/cgi/query-pr.cgi?pr=180065. t.Skipf("not supported on %q", runtime.GOOS) - case "dragonfly", "plan9", "solaris", "windows": + case "plan9", "solaris", "windows": t.Skipf("not supported on %q", runtime.GOOS) } if !supportsIPv6 { @@ -97,7 +97,7 @@ func TestPacketConnReadWriteMulticastUDP(t *testing.T) { func TestPacketConnReadWriteMulticastICMP(t *testing.T) { switch runtime.GOOS { - case "dragonfly", "plan9", "solaris", "windows": + case "plan9", "solaris", "windows": t.Skipf("not supported on %q", runtime.GOOS) } if !supportsIPv6 { diff --git a/ipv6/multicastlistener_test.go b/ipv6/multicastlistener_test.go index 3881e5db..3070476d 100644 --- a/ipv6/multicastlistener_test.go +++ b/ipv6/multicastlistener_test.go @@ -21,7 +21,7 @@ var udpMultipleGroupListenerTests = []net.Addr{ func TestUDPSinglePacketConnWithMultipleGroupListeners(t *testing.T) { switch runtime.GOOS { - case "dragonfly", "plan9", "solaris", "windows": + case "plan9", "solaris", "windows": t.Skipf("not supported on %q", runtime.GOOS) } if !supportsIPv6 { @@ -61,7 +61,7 @@ func TestUDPSinglePacketConnWithMultipleGroupListeners(t *testing.T) { func TestUDPMultiplePacketConnWithMultipleGroupListeners(t *testing.T) { switch runtime.GOOS { - case "dragonfly", "plan9", "solaris", "windows": + case "plan9", "solaris", "windows": t.Skipf("not supported on %q", runtime.GOOS) } if !supportsIPv6 { @@ -113,7 +113,7 @@ func TestUDPMultiplePacketConnWithMultipleGroupListeners(t *testing.T) { func TestUDPPerInterfaceSinglePacketConnWithSingleGroupListener(t *testing.T) { switch runtime.GOOS { - case "dragonfly", "plan9", "solaris", "windows": + case "plan9", "solaris", "windows": t.Skipf("not supported on %q", runtime.GOOS) } if !supportsIPv6 { @@ -156,7 +156,7 @@ func TestUDPPerInterfaceSinglePacketConnWithSingleGroupListener(t *testing.T) { func TestIPSinglePacketConnWithSingleGroupListener(t *testing.T) { switch runtime.GOOS { - case "dragonfly", "plan9", "solaris", "windows": + case "plan9", "solaris", "windows": t.Skipf("not supported on %q", runtime.GOOS) } if !supportsIPv6 { diff --git a/ipv6/multicastsockopt_test.go b/ipv6/multicastsockopt_test.go index 650dadd0..86992da2 100644 --- a/ipv6/multicastsockopt_test.go +++ b/ipv6/multicastsockopt_test.go @@ -22,7 +22,7 @@ var packetConnMulticastSocketOptionTests = []struct { func TestPacketConnMulticastSocketOptions(t *testing.T) { switch runtime.GOOS { - case "dragonfly", "plan9", "solaris", "windows": + case "plan9", "solaris", "windows": t.Skipf("not supported on %q", runtime.GOOS) } if !supportsIPv6 { diff --git a/ipv6/readwrite_test.go b/ipv6/readwrite_test.go index ff4e67b8..29f32ec7 100644 --- a/ipv6/readwrite_test.go +++ b/ipv6/readwrite_test.go @@ -90,7 +90,7 @@ func benchmarkReadWriteIPv6UDP(b *testing.B, p *ipv6.PacketConn, wb, rb []byte, func TestPacketConnConcurrentReadWriteUnicastUDP(t *testing.T) { switch runtime.GOOS { - case "dragonfly", "plan9", "solaris", "windows": + case "plan9", "solaris", "windows": t.Skipf("not supported on %q", runtime.GOOS) } if !supportsIPv6 { diff --git a/ipv6/sockopt_rfc3493_bsd.go b/ipv6/sockopt_rfc3493_bsd.go index 352a1617..95329ff9 100644 --- a/ipv6/sockopt_rfc3493_bsd.go +++ b/ipv6/sockopt_rfc3493_bsd.go @@ -2,7 +2,7 @@ // Use of this source code is governed by a BSD-style // license that can be found in the LICENSE file. -// +build darwin freebsd netbsd openbsd +// +build darwin dragonfly freebsd netbsd openbsd package ipv6 diff --git a/ipv6/sockopt_rfc3493_unix.go b/ipv6/sockopt_rfc3493_unix.go index a9f5e113..c4502429 100644 --- a/ipv6/sockopt_rfc3493_unix.go +++ b/ipv6/sockopt_rfc3493_unix.go @@ -2,7 +2,7 @@ // Use of this source code is governed by a BSD-style // license that can be found in the LICENSE file. -// +build darwin freebsd linux netbsd openbsd +// +build darwin dragonfly freebsd linux netbsd openbsd package ipv6 diff --git a/ipv6/sockopt_rfc3542_stub.go b/ipv6/sockopt_rfc3542_stub.go index 2b383a26..7d7eae5d 100644 --- a/ipv6/sockopt_rfc3542_stub.go +++ b/ipv6/sockopt_rfc3542_stub.go @@ -2,7 +2,7 @@ // Use of this source code is governed by a BSD-style // license that can be found in the LICENSE file. -// +build dragonfly plan9 solaris +// +build plan9 solaris package ipv6 diff --git a/ipv6/sockopt_rfc3542_unix.go b/ipv6/sockopt_rfc3542_unix.go index da9111cd..7efd726a 100644 --- a/ipv6/sockopt_rfc3542_unix.go +++ b/ipv6/sockopt_rfc3542_unix.go @@ -2,7 +2,7 @@ // Use of this source code is governed by a BSD-style // license that can be found in the LICENSE file. -// +build freebsd linux netbsd openbsd +// +build dragonfly freebsd linux netbsd openbsd package ipv6 diff --git a/ipv6/sockopt_test.go b/ipv6/sockopt_test.go index 9c899e1b..a955e872 100644 --- a/ipv6/sockopt_test.go +++ b/ipv6/sockopt_test.go @@ -24,7 +24,7 @@ func init() { var condFatalf = func() func(*testing.T, string, ...interface{}) { // A few APIs are not implemented yet on some platforms. switch runtime.GOOS { - case "darwin", "dragonfly", "plan9", "solaris", "windows": + case "darwin", "plan9", "solaris", "windows": return (*testing.T).Logf } return (*testing.T).Fatalf @@ -32,7 +32,7 @@ var condFatalf = func() func(*testing.T, string, ...interface{}) { func TestConnInitiatorPathMTU(t *testing.T) { switch runtime.GOOS { - case "dragonfly", "plan9", "solaris", "windows": + case "plan9", "solaris", "windows": t.Skipf("not supported on %q", runtime.GOOS) } if !supportsIPv6 { @@ -65,7 +65,7 @@ func TestConnInitiatorPathMTU(t *testing.T) { func TestConnResponderPathMTU(t *testing.T) { switch runtime.GOOS { - case "dragonfly", "plan9", "solaris", "windows": + case "plan9", "solaris", "windows": t.Skipf("not supported on %q", runtime.GOOS) } if !supportsIPv6 { @@ -98,7 +98,7 @@ func TestConnResponderPathMTU(t *testing.T) { func TestPacketConnChecksum(t *testing.T) { switch runtime.GOOS { - case "dragonfly", "plan9", "solaris", "windows": + case "plan9", "solaris", "windows": t.Skipf("not supported on %q", runtime.GOOS) } if !supportsIPv6 { diff --git a/ipv6/sys_bsd.go b/ipv6/sys_bsd.go index 4a08217f..051610a3 100644 --- a/ipv6/sys_bsd.go +++ b/ipv6/sys_bsd.go @@ -2,7 +2,7 @@ // Use of this source code is governed by a BSD-style // license that can be found in the LICENSE file. -// +build freebsd netbsd openbsd +// +build dragonfly freebsd netbsd openbsd package ipv6 diff --git a/ipv6/sys_unix.go b/ipv6/sys_unix.go index 40cdfc4d..899d14ed 100644 --- a/ipv6/sys_unix.go +++ b/ipv6/sys_unix.go @@ -2,7 +2,7 @@ // Use of this source code is governed by a BSD-style // license that can be found in the LICENSE file. -// +build darwin freebsd linux netbsd openbsd +// +build darwin dragonfly freebsd linux netbsd openbsd package ipv6 diff --git a/ipv6/syscall_unix.go b/ipv6/syscall_unix.go index d88dab52..04497596 100644 --- a/ipv6/syscall_unix.go +++ b/ipv6/syscall_unix.go @@ -2,7 +2,7 @@ // Use of this source code is governed by a BSD-style // license that can be found in the LICENSE file. -// +build darwin freebsd linux,amd64 linux,arm netbsd openbsd +// +build darwin dragonfly freebsd linux,amd64 linux,arm netbsd openbsd package ipv6 diff --git a/ipv6/unicast_test.go b/ipv6/unicast_test.go index 6ad93ed6..e31bc462 100644 --- a/ipv6/unicast_test.go +++ b/ipv6/unicast_test.go @@ -16,7 +16,7 @@ import ( func TestPacketConnReadWriteUnicastUDP(t *testing.T) { switch runtime.GOOS { - case "dragonfly", "plan9", "solaris", "windows": + case "plan9", "solaris", "windows": t.Skipf("not supported on %q", runtime.GOOS) } if !supportsIPv6 { @@ -77,7 +77,7 @@ func TestPacketConnReadWriteUnicastUDP(t *testing.T) { func TestPacketConnReadWriteUnicastICMP(t *testing.T) { switch runtime.GOOS { - case "dragonfly", "plan9", "solaris", "windows": + case "plan9", "solaris", "windows": t.Skipf("not supported on %q", runtime.GOOS) } if !supportsIPv6 { diff --git a/ipv6/unicastsockopt_test.go b/ipv6/unicastsockopt_test.go index e3967ca6..71735b9d 100644 --- a/ipv6/unicastsockopt_test.go +++ b/ipv6/unicastsockopt_test.go @@ -14,7 +14,7 @@ import ( func TestConnUnicastSocketOptions(t *testing.T) { switch runtime.GOOS { - case "dragonfly", "plan9", "solaris", "windows": + case "plan9", "solaris", "windows": t.Skipf("not supported on %q", runtime.GOOS) } if !supportsIPv6 { @@ -50,7 +50,7 @@ var packetConnUnicastSocketOptionTests = []struct { func TestPacketConnUnicastSocketOptions(t *testing.T) { switch runtime.GOOS { - case "dragonfly", "plan9", "solaris", "windows": + case "plan9", "solaris", "windows": t.Skipf("not supported on %q", runtime.GOOS) } if !supportsIPv6 {