diff --git a/Source/WebCore/PAL/pal/crypto/qt/CryptoDigestQt.cpp b/Source/WebCore/PAL/pal/crypto/qt/CryptoDigestQt.cpp index f23965216f157..d63274a0e4717 100644 --- a/Source/WebCore/PAL/pal/crypto/qt/CryptoDigestQt.cpp +++ b/Source/WebCore/PAL/pal/crypto/qt/CryptoDigestQt.cpp @@ -79,7 +79,7 @@ std::unique_ptr CryptoDigest::create(CryptoDigest::Algorithm algor void CryptoDigest::addBytes(std::span input) { - m_context->hash.addData(QByteArrayView(input.data(), input.size())); + m_context->hash.addData(QByteArray(reinterpret_cast(input.data()), static_cast(input.size()))); } Vector CryptoDigest::computeHash() @@ -92,7 +92,7 @@ Vector CryptoDigest::computeHash() std::optional> CryptoDigest::computeHash(Algorithm algorithm, const Vector& input, UseCryptoKit) { QCryptographicHash hash(toQtAlgorithm(algorithm)); - hash.addData(QByteArrayView(input.span().data(), input.span().size())); + hash.addData(QByteArray(reinterpret_cast(input.span().data()), static_cast(input.span().size()))); QByteArray digest = hash.result(); return Vector(std::span { reinterpret_cast(digest.constData()), static_cast(digest.size()) });