Remove qSort usages from QDnsLookup
Change-Id: I2f7dfcfdf13cdd85af5ba251478e10cafe7f649b Reviewed-by: Shane Kearns <shane.kearns@accenture.com>
This commit is contained in:
parent
602ea84f44
commit
6e7ab54862
@ -47,6 +47,8 @@
|
|||||||
#include <qthreadstorage.h>
|
#include <qthreadstorage.h>
|
||||||
#include <qurl.h>
|
#include <qurl.h>
|
||||||
|
|
||||||
|
#include <algorithm>
|
||||||
|
|
||||||
QT_BEGIN_NAMESPACE
|
QT_BEGIN_NAMESPACE
|
||||||
|
|
||||||
Q_GLOBAL_STATIC(QDnsLookupThreadPool, theDnsLookupThreadPool);
|
Q_GLOBAL_STATIC(QDnsLookupThreadPool, theDnsLookupThreadPool);
|
||||||
@ -69,7 +71,7 @@ static void qt_qdnsmailexchangerecord_sort(QList<QDnsMailExchangeRecord> &record
|
|||||||
return;
|
return;
|
||||||
|
|
||||||
// Order the records by preference.
|
// Order the records by preference.
|
||||||
qSort(records.begin(), records.end(), qt_qdnsmailexchangerecord_less_than);
|
std::sort(records.begin(), records.end(), qt_qdnsmailexchangerecord_less_than);
|
||||||
|
|
||||||
int i = 0;
|
int i = 0;
|
||||||
while (i < records.size()) {
|
while (i < records.size()) {
|
||||||
@ -112,7 +114,7 @@ static void qt_qdnsservicerecord_sort(QList<QDnsServiceRecord> &records)
|
|||||||
|
|
||||||
// Order the records by priority, and for records with an equal
|
// Order the records by priority, and for records with an equal
|
||||||
// priority, put records with a zero weight first.
|
// priority, put records with a zero weight first.
|
||||||
qSort(records.begin(), records.end(), qt_qdnsservicerecord_less_than);
|
std::sort(records.begin(), records.end(), qt_qdnsservicerecord_less_than);
|
||||||
|
|
||||||
int i = 0;
|
int i = 0;
|
||||||
while (i < records.size()) {
|
while (i < records.size()) {
|
||||||
|
Loading…
Reference in New Issue
Block a user