Fix panic in tcp.init for incorrectly formatted listen addresses

This commit is contained in:
Neil Alexander 2022-09-01 16:56:42 +01:00
parent 486ffebedd
commit 4f2abece81
No known key found for this signature in database
GPG Key ID: A02A2019A2BB0944

View File

@ -109,6 +109,7 @@ func (t *tcp) init(l *links, listeners []ListenAddress) error {
u, err := url.Parse(string(listenaddr))
if err != nil {
t.links.core.log.Errorln("Failed to parse listener: listener", listenaddr, "is not correctly formatted, ignoring")
continue
}
if _, err := t.listenURL(u, ""); err != nil {
return err