tcplistener

package
v0.13.7 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Feb 12, 2020 License: Apache-2.0 Imports: 3 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type RawListener

type RawListener struct {
	*net.TCPListener
}

RawListener is the place where we accept new TCP connections and set specific options on such connections. We unconditionally set the keepalive timeout for all connections, so that dead TCP connections (e.g. laptop closed amid a download) eventually go away.

Note: Adapted from net/http package.

func (*RawListener) Accept

func (ln *RawListener) Accept() (net.Conn, error)

Accept accepts the TCP connection and then sets the connection's options.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL