diff options
author | lloyd <[email protected]> | 2010-10-12 15:45:16 +0000 |
---|---|---|
committer | lloyd <[email protected]> | 2010-10-12 15:45:16 +0000 |
commit | a263ae6b9cfb5e93e3f446bd736ab3f86ba3c681 (patch) | |
tree | 31076d3432d35ea24c235c2b8064d5c86d7665c0 /src/codec/openpgp | |
parent | 18a58396b7bb2925a33c57b17f1820b386b54c2d (diff) |
s/u32bit/size_t/ in codec and benchmark
Diffstat (limited to 'src/codec/openpgp')
-rw-r--r-- | src/codec/openpgp/openpgp.cpp | 12 | ||||
-rw-r--r-- | src/codec/openpgp/openpgp.h | 4 |
2 files changed, 8 insertions, 8 deletions
diff --git a/src/codec/openpgp/openpgp.cpp b/src/codec/openpgp/openpgp.cpp index ca1ea6d9c..ab9673689 100644 --- a/src/codec/openpgp/openpgp.cpp +++ b/src/codec/openpgp/openpgp.cpp @@ -17,13 +17,13 @@ namespace Botan { * OpenPGP Base64 encoding */ std::string PGP_encode( - const byte input[], u32bit length, + const byte input[], size_t length, const std::string& label, const std::map<std::string, std::string>& headers) { const std::string PGP_HEADER = "-----BEGIN PGP " + label + "-----\n"; const std::string PGP_TRAILER = "-----END PGP " + label + "-----\n"; - const u32bit PGP_WIDTH = 64; + const size_t PGP_WIDTH = 64; std::string pgp_encoded = PGP_HEADER; @@ -57,7 +57,7 @@ std::string PGP_encode( /* * OpenPGP Base64 encoding */ -std::string PGP_encode(const byte input[], u32bit length, +std::string PGP_encode(const byte input[], size_t length, const std::string& type) { std::map<std::string, std::string> empty; @@ -71,11 +71,11 @@ SecureVector<byte> PGP_decode(DataSource& source, std::string& label, std::map<std::string, std::string>& headers) { - const u32bit RANDOM_CHAR_LIMIT = 5; + const size_t RANDOM_CHAR_LIMIT = 5; const std::string PGP_HEADER1 = "-----BEGIN PGP "; const std::string PGP_HEADER2 = "-----"; - u32bit position = 0; + size_t position = 0; while(position != PGP_HEADER1.length()) { @@ -119,7 +119,7 @@ SecureVector<byte> PGP_decode(DataSource& source, } end_of_headers = true; - for(u32bit j = 0; j != this_header.length(); ++j) + for(size_t j = 0; j != this_header.length(); ++j) if(!Charset::is_space(this_header[j])) end_of_headers = false; diff --git a/src/codec/openpgp/openpgp.h b/src/codec/openpgp/openpgp.h index 1e2cf10f0..0cd77d53a 100644 --- a/src/codec/openpgp/openpgp.h +++ b/src/codec/openpgp/openpgp.h @@ -22,7 +22,7 @@ namespace Botan { */ BOTAN_DLL std::string PGP_encode( const byte input[], - u32bit length, + size_t length, const std::string& label, const std::map<std::string, std::string>& headers); @@ -33,7 +33,7 @@ BOTAN_DLL std::string PGP_encode( */ BOTAN_DLL std::string PGP_encode( const byte input[], - u32bit length, + size_t length, const std::string& label); /** |