QLibrary: fix use of deprecated QByteArrayMatcher::indexIn(p, n)
Use the QByteArrayView overload instead. Deprecated since 6.3, so backporting: Pick-to: 6.4 6.3 Change-Id: I529104cad59260eed371cedb1ae84a7e9086bbf6 Reviewed-by: Sona Kurazyan <sona.kurazyan@qt.io>
This commit is contained in:
parent
1b8b802455
commit
4e66c69bad
@ -188,7 +188,7 @@ static QLibraryScanResult qt_find_pattern(const char *s, qsizetype s_len, QStrin
|
|||||||
static_assert(pattern == magic);
|
static_assert(pattern == magic);
|
||||||
return qMakeStaticByteArrayMatcher(pattern);
|
return qMakeStaticByteArrayMatcher(pattern);
|
||||||
}();
|
}();
|
||||||
qsizetype i = matcher.indexIn(s, s_len);
|
qsizetype i = matcher.indexIn({s, s_len});
|
||||||
if (i < 0) {
|
if (i < 0) {
|
||||||
*errMsg = QLibrary::tr("'%1' is not a Qt plugin").arg(*errMsg);
|
*errMsg = QLibrary::tr("'%1' is not a Qt plugin").arg(*errMsg);
|
||||||
return QLibraryScanResult{};
|
return QLibraryScanResult{};
|
||||||
|
Loading…
x
Reference in New Issue
Block a user