diff options
Diffstat (limited to 'conn')
-rw-r--r-- | conn/bind_linux.go | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/conn/bind_linux.go b/conn/bind_linux.go index f11f031..03e8707 100644 --- a/conn/bind_linux.go +++ b/conn/bind_linux.go @@ -331,7 +331,7 @@ func create4(port uint16) (int, uint16, error) { fd, err := unix.Socket( unix.AF_INET, - unix.SOCK_DGRAM, + unix.SOCK_DGRAM|unix.SOCK_CLOEXEC, 0, ) if err != nil { @@ -373,7 +373,7 @@ func create6(port uint16) (int, uint16, error) { fd, err := unix.Socket( unix.AF_INET6, - unix.SOCK_DGRAM, + unix.SOCK_DGRAM|unix.SOCK_CLOEXEC, 0, ) if err != nil { |