mirror of
https://github.com/octoleo/syncthing.git
synced 2025-01-22 22:58:25 +00:00
skip-check: authors
GitHub-Pull-Request: https://github.com/syncthing/syncthing/pull/3650
This commit is contained in:
parent
1e54a3e801
commit
96e8f94833
@ -326,8 +326,9 @@ func handlePostRequest(w http.ResponseWriter, r *http.Request) {
|
|||||||
return
|
return
|
||||||
}
|
}
|
||||||
|
|
||||||
|
ip := net.ParseIP(host)
|
||||||
// The client did not provide an IP address, use the IP address of the client.
|
// The client did not provide an IP address, use the IP address of the client.
|
||||||
if host == "" {
|
if ip == nil || ip.IsUnspecified() {
|
||||||
uri.Host = net.JoinHostPort(rhost, port)
|
uri.Host = net.JoinHostPort(rhost, port)
|
||||||
newRelay.URL = uri.String()
|
newRelay.URL = uri.String()
|
||||||
} else if host != rhost {
|
} else if host != rhost {
|
||||||
|
Loading…
x
Reference in New Issue
Block a user