diff options
| author | Jeffrey Walton <noloader@gmail.com> | 2015-08-03 19:11:23 -0400 |
|---|---|---|
| committer | Jeffrey Walton <noloader@gmail.com> | 2015-08-03 19:11:23 -0400 |
| commit | 1e103c0e5b2a55bef4a3561b388c78dd5f8181ca (patch) | |
| tree | bebc016cd4485c0668ad854047f270a7fb8937ac /datatest.cpp | |
| parent | 7e6c9438da8787b6ea202dcaaea8aee0eff6e158 (diff) | |
| download | cryptopp-git-1e103c0e5b2a55bef4a3561b388c78dd5f8181ca.tar.gz | |
Completed cutover to unscoped auto_ptr (which will use Crypto++'s namespace version)
Diffstat (limited to 'datatest.cpp')
| -rw-r--r-- | datatest.cpp | 10 |
1 files changed, 6 insertions, 4 deletions
diff --git a/datatest.cpp b/datatest.cpp index 5595c4a1..14ae4cab 100644 --- a/datatest.cpp +++ b/datatest.cpp @@ -1,6 +1,8 @@ // datatest.cpp - written and placed in public domain by Wei Dai #include "config.h" +#include "stdcpp.h" +#include "smartptr.h" #include "integer.h" #include "factory.h" #include "filters.h" @@ -208,8 +210,8 @@ void TestSignatureScheme(TestData &v) std::string name = GetRequiredDatum(v, "Name"); std::string test = GetRequiredDatum(v, "Test"); - std::auto_ptr<PK_Signer> signer(ObjectFactoryRegistry<PK_Signer>::Registry().CreateObject(name.c_str())); - std::auto_ptr<PK_Verifier> verifier(ObjectFactoryRegistry<PK_Verifier>::Registry().CreateObject(name.c_str())); + auto_ptr<PK_Signer> signer(ObjectFactoryRegistry<PK_Signer>::Registry().CreateObject(name.c_str())); + auto_ptr<PK_Verifier> verifier(ObjectFactoryRegistry<PK_Verifier>::Registry().CreateObject(name.c_str())); TestDataNameValuePairs pairs(v); @@ -285,8 +287,8 @@ void TestAsymmetricCipher(TestData &v) std::string name = GetRequiredDatum(v, "Name"); std::string test = GetRequiredDatum(v, "Test"); - std::auto_ptr<PK_Encryptor> encryptor(ObjectFactoryRegistry<PK_Encryptor>::Registry().CreateObject(name.c_str())); - std::auto_ptr<PK_Decryptor> decryptor(ObjectFactoryRegistry<PK_Decryptor>::Registry().CreateObject(name.c_str())); + auto_ptr<PK_Encryptor> encryptor(ObjectFactoryRegistry<PK_Encryptor>::Registry().CreateObject(name.c_str())); + auto_ptr<PK_Decryptor> decryptor(ObjectFactoryRegistry<PK_Decryptor>::Registry().CreateObject(name.c_str())); std::string keyFormat = GetRequiredDatum(v, "KeyFormat"); |
