mirror of
https://github.com/octoleo/syncthing.git
synced 2025-02-11 08:18:26 +00:00
Announce actual port when UPnP is disabled (fixes #657)
This commit is contained in:
parent
3a8255bda1
commit
50a4170541
@ -530,6 +530,14 @@ nextRepo:
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// The default port we announce, possibly modified by setupUPnP next.
|
||||||
|
|
||||||
|
addr, err := net.ResolveTCPAddr("tcp", cfg.Options.ListenAddress[0])
|
||||||
|
if err != nil {
|
||||||
|
l.Fatalln("Bad listen address:", err)
|
||||||
|
}
|
||||||
|
externalPort = addr.Port
|
||||||
|
|
||||||
// UPnP
|
// UPnP
|
||||||
|
|
||||||
if cfg.Options.UPnPEnabled {
|
if cfg.Options.UPnPEnabled {
|
||||||
|
Loading…
x
Reference in New Issue
Block a user