Skip to content

Commit

Permalink
Bug 1407560 - Tweak integer handling for CID 1419486, r=ttaubert
Browse files Browse the repository at this point in the history
  • Loading branch information
martinthomson committed Oct 11, 2017
1 parent b90842e commit dac31eb
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion gtests/pk11_gtest/pk11_signature_test.h
Expand Up @@ -74,7 +74,9 @@ class Pk11SignatureTest : public ::testing::Test {
DataBuffer* sig) {
SECItem hashItem = {siBuffer, toUcharPtr(hash.data()),
static_cast<unsigned int>(hash.len())};
sig->Allocate(static_cast<size_t>(PK11_SignatureLen(privKey.get())));
int sigLen = PK11_SignatureLen(privKey.get());
EXPECT_LT(0, sigLen);
sig->Allocate(static_cast<size_t>(sigLen));
SECItem sigItem = {siBuffer, toUcharPtr(sig->data()),
static_cast<unsigned int>(sig->len())};
SECStatus rv = PK11_SignWithMechanism(privKey.get(), mechanism_,
Expand Down

0 comments on commit dac31eb

Please sign in to comment.