diff --git a/src/sshagent/OpenSSHKey.cpp b/src/sshagent/OpenSSHKey.cpp index 1beffc8f1d..ee2e32143d 100644 --- a/src/sshagent/OpenSSHKey.cpp +++ b/src/sshagent/OpenSSHKey.cpp @@ -308,7 +308,7 @@ bool OpenSSHKey::parsePKCS1PEM(const QByteArray& in) return false; } - if (QString::fromLatin1(magic) != "openssh-key-v1") { + if (QString::fromLatin1(magic.toStdString().c_str()) != "openssh-key-v1") { m_error = tr("Key file magic header id invalid"); return false; } diff --git a/tests/TestPasskeys.cpp b/tests/TestPasskeys.cpp index 4e5db2803b..5d8000dc93 100644 --- a/tests/TestPasskeys.cpp +++ b/tests/TestPasskeys.cpp @@ -259,7 +259,7 @@ void TestPasskeys::testCreatingAttestationObjectWithEC() TestingVariables testingVariables = {id, predefinedFirst, predefinedSecond}; auto result = browserPasskeys()->buildAttestationObject(publicKeyCredentialOptions, "", id, testingVariables); QCOMPARE( - QString(result.cborEncoded), + QString(result.cborEncoded.toStdString().c_str()), QString("\xA3" "cfmtdnonegattStmt\xA0hauthDataX\xA4t\xA6\xEA\x92\x13\xC9\x9C/t\xB2$\x92\xB3 \xCF@&*\x94\xC1\xA9P\xA0" "9\x7F)%\x0B`\x84\x1E\xF0"