Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(2407)

Unified Diff: crypto/signature_creator_nss.cc

Issue 1539353003: Switch to standard integer types in crypto/. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: fix Created 5 years ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « crypto/signature_creator.h ('k') | crypto/signature_creator_openssl.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: crypto/signature_creator_nss.cc
diff --git a/crypto/signature_creator_nss.cc b/crypto/signature_creator_nss.cc
index da03312881dbb9a5009c08e78023b5bd897183c8..bf204134b9defa0711bb39a50c26d2d63425b7d3 100644
--- a/crypto/signature_creator_nss.cc
+++ b/crypto/signature_creator_nss.cc
@@ -6,6 +6,7 @@
#include <cryptohi.h>
#include <keyhi.h>
+#include <stdint.h>
#include <stdlib.h>
#include "base/logging.h"
@@ -68,9 +69,9 @@ SignatureCreator* SignatureCreator::Create(RSAPrivateKey* key,
// static
bool SignatureCreator::Sign(RSAPrivateKey* key,
HashAlgorithm hash_alg,
- const uint8* data,
+ const uint8_t* data,
int data_len,
- std::vector<uint8>* signature) {
+ std::vector<uint8_t>* signature) {
SECItem data_item;
data_item.type = siBuffer;
data_item.data = const_cast<unsigned char*>(data);
@@ -89,7 +90,7 @@ bool SignatureCreator::Sign(RSAPrivateKey* key,
return true;
}
-bool SignatureCreator::Update(const uint8* data_part, int data_part_len) {
+bool SignatureCreator::Update(const uint8_t* data_part, int data_part_len) {
SECStatus rv = SGN_Update(sign_context_, data_part, data_part_len);
if (rv != SECSuccess) {
NOTREACHED();
@@ -99,7 +100,7 @@ bool SignatureCreator::Update(const uint8* data_part, int data_part_len) {
return true;
}
-bool SignatureCreator::Final(std::vector<uint8>* signature) {
+bool SignatureCreator::Final(std::vector<uint8_t>* signature) {
SECItem signature_item;
SECStatus rv = SGN_End(sign_context_, &signature_item);
if (rv != SECSuccess) {
« no previous file with comments | « crypto/signature_creator.h ('k') | crypto/signature_creator_openssl.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698