mirror of
https://github.com/etcd-io/etcd.git
synced 2024-09-27 06:25:44 +00:00
chore(server/listener): improve comment
This commit is contained in:
parent
a3cbf02597
commit
8afa93ed59
@ -22,8 +22,8 @@ func TLSServerConfig(info *TLSInfo) *tls.Config {
|
||||
}
|
||||
|
||||
// NewListener creates a net.Listener
|
||||
// If the given scheme is "https", it will use TLS config to set listener.
|
||||
// If any error happens, this function will call log.Fatal
|
||||
// This function does listening only and finishes quickly.
|
||||
func NewListener(scheme, addr string, cfg *tls.Config) net.Listener {
|
||||
if scheme == "https" {
|
||||
l, err := newTLSListener(addr, cfg)
|
||||
|
Loading…
x
Reference in New Issue
Block a user