Allow listen.host to contain names (#825)

This commit is contained in:
Nate Brown
2023-04-05 11:29:26 -05:00
committed by GitHub
parent e0553822b0
commit 3cb4e0ef57
5 changed files with 21 additions and 8 deletions

View File

@@ -45,9 +45,9 @@ type Conn struct {
l *logrus.Logger
}
func NewListener(l *logrus.Logger, ip string, port int, _ bool, _ int) (*Conn, error) {
func NewListener(l *logrus.Logger, ip net.IP, port int, _ bool, _ int) (*Conn, error) {
return &Conn{
Addr: &Addr{net.ParseIP(ip), uint16(port)},
Addr: &Addr{ip, uint16(port)},
RxPackets: make(chan *Packet, 10),
TxPackets: make(chan *Packet, 10),
l: l,