File: xsocket_cloexec.go

package info (click to toggle)
golang-github-insomniacslk-dhcp 0.0~git20251020.175e84f-1
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid
  • size: 1,104 kB
  • sloc: makefile: 3
file content (9 lines) | stat: -rw-r--r-- 230 bytes parent folder | download
1
2
3
4
5
6
7
8
9
//go:build dragonfly || freebsd || linux || netbsd || openbsd

package xsocket

import "golang.org/x/sys/unix"

func socketCloexec(domain, typ, proto int) (int, error) {
	return unix.Socket(domain, typ|unix.SOCK_CLOEXEC, proto)
}