File: tcplisten_bsd.go

package info (click to toggle)
golang-github-valyala-tcplisten 0.0~git20210309.652d3b4-2
  • links: PTS, VCS
  • area: main
  • in suites: bookworm
  • size: 120 kB
  • sloc: makefile: 2
file content (24 lines) | stat: -rw-r--r-- 451 bytes parent folder | download | duplicates (3)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
// +build darwin dragonfly freebsd netbsd openbsd rumprun

package tcplisten

import (
	"syscall"
)

const soReusePort = syscall.SO_REUSEPORT

func enableDeferAccept(fd int) error {
	// TODO: implement SO_ACCEPTFILTER:dataready here
	return nil
}

func enableFastOpen(fd int) error {
	// TODO: implement TCP_FASTOPEN when it will be ready
	return nil
}

func soMaxConn() (int, error) {
	// TODO: properly implement it
	return syscall.SOMAXCONN, nil
}