fixed wrong code sent in previous commit (ip heuristic sorting)

This commit is contained in:
Luis Ángel San Martín
2015-03-18 18:46:05 +01:00
parent c77ef524de
commit 55d7e0ae22

View File

@ -249,10 +249,13 @@ void ServerConfigDialog::generateQR()
} }
#endif #endif
stl::sort(otherAddresses.begin(),otherAddresses.end(),ipComparator); std::sort(otherAddresses.begin(),otherAddresses.end(),ipComparator);
if(otherAddresses.length()>0) if(!otherAddresses.isEmpty())
dir = otherAddresses.pop_front(); {
dir = otherAddresses.first();
otherAddresses.pop_front();
}
if(otherAddresses.length()>0 || !dir.isEmpty()) if(otherAddresses.length()>0 || !dir.isEmpty())
{ {