1
0
Fork 0
mirror of https://github.com/vanitasvitae/Smack.git synced 2024-11-24 21:12:05 +01:00

Also check that srvRecords is not empty

This commit is contained in:
Florian Schmaus 2017-01-24 20:13:40 +01:00
parent 9526926cd3
commit 1bcb5a2d1a

View file

@ -185,7 +185,7 @@ public class DNSUtil {
}
List<SRVRecord> srvRecords = dnsResolver.lookupSRVRecords(srvDomain, failedAddresses, dnssecMode);
if (srvRecords != null) {
if (srvRecords != null && !srvRecords.isEmpty()) {
if (LOGGER.isLoggable(Level.FINE)) {
String logMessage = "Resolved SRV RR for " + srvDomain + ":";
for (SRVRecord r : srvRecords)