diff options
author | lloyd <[email protected]> | 2012-05-18 20:44:34 +0000 |
---|---|---|
committer | lloyd <[email protected]> | 2012-05-18 20:44:34 +0000 |
commit | 8383b0b503c812e45f2780217b048a19a8946853 (patch) | |
tree | 939403bad80ee2b1e13b69c82adc316422a9c7d6 /src/pubkey | |
parent | c691561f3198f481c13457433efbccc1c9fcd898 (diff) |
Replace 0 and NULL pointer constants with nullptr. Also fix an old
style cast in secmem.h
Diffstat (limited to 'src/pubkey')
-rw-r--r-- | src/pubkey/pk_algs.cpp | 4 | ||||
-rw-r--r-- | src/pubkey/pubkey.cpp | 10 |
2 files changed, 7 insertions, 7 deletions
diff --git a/src/pubkey/pk_algs.cpp b/src/pubkey/pk_algs.cpp index 863eb57e4..9673199e0 100644 --- a/src/pubkey/pk_algs.cpp +++ b/src/pubkey/pk_algs.cpp @@ -98,7 +98,7 @@ Public_Key* make_public_key(const AlgorithmIdentifier& alg_id, return new ECDH_PublicKey(alg_id, key_bits); #endif - return 0; + return nullptr; } Private_Key* make_private_key(const AlgorithmIdentifier& alg_id, @@ -154,7 +154,7 @@ Private_Key* make_private_key(const AlgorithmIdentifier& alg_id, return new ECDH_PrivateKey(alg_id, key_bits); #endif - return 0; + return nullptr; } } diff --git a/src/pubkey/pubkey.cpp b/src/pubkey/pubkey.cpp index 370eeddbf..c27cf4a05 100644 --- a/src/pubkey/pubkey.cpp +++ b/src/pubkey/pubkey.cpp @@ -38,7 +38,7 @@ PK_Encryptor_EME::PK_Encryptor_EME(const Public_Key& key, throw Lookup_Error("PK_Encryptor_EME: No working engine for " + key.algo_name()); - eme = (eme_name == "Raw") ? 0 : get_eme(eme_name); + eme = (eme_name == "Raw") ? nullptr : get_eme(eme_name); } /* @@ -98,7 +98,7 @@ PK_Decryptor_EME::PK_Decryptor_EME(const Private_Key& key, throw Lookup_Error("PK_Decryptor_EME: No working engine for " + key.algo_name()); - eme = (eme_name == "Raw") ? 0 : get_eme(eme_name); + eme = (eme_name == "Raw") ? nullptr : get_eme(eme_name); } /* @@ -130,8 +130,8 @@ PK_Signer::PK_Signer(const Private_Key& key, { Algorithm_Factory::Engine_Iterator i(global_state().algorithm_factory()); - op = 0; - verify_op = 0; + op = nullptr; + verify_op = nullptr; while(const Engine* engine = i.next()) { @@ -370,7 +370,7 @@ PK_Key_Agreement::PK_Key_Agreement(const PK_Key_Agreement_Key& key, throw Lookup_Error("PK_Key_Agreement: No working engine for " + key.algo_name()); - kdf = (kdf_name == "Raw") ? 0 : get_kdf(kdf_name); + kdf = (kdf_name == "Raw") ? nullptr : get_kdf(kdf_name); } SymmetricKey PK_Key_Agreement::derive_key(size_t key_len, const byte in[], |