diff options
Diffstat (limited to 'src/network/kernel/qnetworkproxy_mac.cpp')
-rw-r--r-- | src/network/kernel/qnetworkproxy_mac.cpp | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/src/network/kernel/qnetworkproxy_mac.cpp b/src/network/kernel/qnetworkproxy_mac.cpp index 67fda24ea6..4c582bfa71 100644 --- a/src/network/kernel/qnetworkproxy_mac.cpp +++ b/src/network/kernel/qnetworkproxy_mac.cpp @@ -45,7 +45,7 @@ #include <CoreFoundation/CoreFoundation.h> #include <SystemConfiguration/SystemConfiguration.h> -#include <QtCore/QRegExp> +#include <QtCore/QRegularExpression> #include <QtCore/QStringList> #include <QtCore/QUrl> #include <QtCore/qendian.h> @@ -110,8 +110,9 @@ static bool isHostExcluded(CFDictionaryRef dict, const QString &host) return true; // excluded } else { // do wildcard matching - QRegExp rx(entry, Qt::CaseInsensitive, QRegExp::Wildcard); - if (rx.exactMatch(host)) + QRegularExpression rx(QRegularExpression::wildcardToRegularExpression(entry), + QRegularExpression::CaseInsensitiveOption); + if (rx.match(host).hasMatch()) return true; } } |