|
|
|
@ -44,8 +44,8 @@ func connect(options xmpp.Options, directTLS bool) (*xmpp.Client, error) {
|
|
|
|
|
if _, addrs, err := net.LookupSRV("xmpp-client", "tcp", server); err == nil {
|
|
|
|
|
if len(addrs) > 0 {
|
|
|
|
|
for _, adr := range addrs {
|
|
|
|
|
srvMixed = append(srvMixed, srv{adr.Target, false,
|
|
|
|
|
adr.Port, adr.Priority, adr.Weight})
|
|
|
|
|
srvMixed = append(srvMixed, srv{strings.TrimSuffix(adr.Target, "."),
|
|
|
|
|
false, adr.Port, adr.Priority, adr.Weight})
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
@ -54,8 +54,9 @@ func connect(options xmpp.Options, directTLS bool) (*xmpp.Client, error) {
|
|
|
|
|
if len(addrs) > 0 {
|
|
|
|
|
if addrs[0].Target != "." {
|
|
|
|
|
for _, adr := range addrs {
|
|
|
|
|
srvMixed = append(srvMixed, srv{adr.Target, true,
|
|
|
|
|
adr.Port, adr.Priority, adr.Weight})
|
|
|
|
|
srvMixed = append(srvMixed,
|
|
|
|
|
srv{strings.TrimSuffix(adr.Target, "."), true, adr.Port,
|
|
|
|
|
adr.Priority, adr.Weight})
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|