Merge "Fix -Wshorten-64-to-32 errors in BoringSSL interactions"

This commit is contained in:
TreeHugger Robot
2021-10-06 21:54:09 +00:00
committed by Android (Google) Code Review
6 changed files with 47 additions and 36 deletions

View File

@@ -205,7 +205,7 @@ std::string WvCdmTestBase::SignHMAC(const std::string& message,
const std::vector<uint8_t>& key) {
uint8_t signature[SHA256_DIGEST_LENGTH];
unsigned int md_len = SHA256_DIGEST_LENGTH;
HMAC(EVP_sha256(), &key[0], key.size(),
HMAC(EVP_sha256(), &key[0], static_cast<int>(key.size()),
reinterpret_cast<const uint8_t*>(message.data()), message.size(),
signature, &md_len);
std::string result(signature, signature + SHA256_DIGEST_LENGTH);