From 5863568c53fd993de3dd83301f07ef6c2dce48f5 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?M=C3=A5rten=20Nordheim?= Date: Mon, 25 Sep 2023 13:57:31 +0200 Subject: [PATCH] QNetworkInfo: Simplify flags check Change-Id: I5e369b9cd2b3abc6c0ac1e632e495b05c506980b Reviewed-by: Thiago Macieira --- src/network/kernel/qnetworkinformation.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/network/kernel/qnetworkinformation.cpp b/src/network/kernel/qnetworkinformation.cpp index a5942e3cf9..750b7d877b 100644 --- a/src/network/kernel/qnetworkinformation.cpp +++ b/src/network/kernel/qnetworkinformation.cpp @@ -238,7 +238,7 @@ QNetworkInformation *QNetworkInformationPrivate::create(QNetworkInformation::Fea return dataHolder->instanceHolder.get(); const auto supportsRequestedFeatures = [features](QNetworkInformationBackendFactory *factory) { - return factory && (factory->featuresSupported() & features) == features; + return factory && factory->featuresSupported().testFlags(features); }; for (auto it = dataHolder->factories.cbegin(), end = dataHolder->factories.cend(); it != end;