Revert "pkg/reuseport: Remove pre-go1.11 impl (#4795)" (#4814)

This reverts commit 4a34e8b897.
This commit is contained in:
Chris O'Haver 2021-08-16 11:57:26 -04:00 committed by GitHub
parent 7d542fec67
commit a977998747
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
2 changed files with 16 additions and 0 deletions

View file

@ -1,3 +1,6 @@
// +build go1.11
// +build aix darwin dragonfly freebsd linux netbsd openbsd
package reuseport
import (

View file

@ -0,0 +1,13 @@
// +build !go1.11 !aix,!darwin,!dragonfly,!freebsd,!linux,!netbsd,!openbsd
package reuseport
import "net"
// Listen is a wrapper around net.Listen.
func Listen(network, addr string) (net.Listener, error) { return net.Listen(network, addr) }
// ListenPacket is a wrapper around net.ListenPacket.
func ListenPacket(network, addr string) (net.PacketConn, error) {
return net.ListenPacket(network, addr)
}