diff options
author | practicalswift <practicalswift@users.noreply.github.com> | 2017-08-15 07:46:56 +0200 |
---|---|---|
committer | practicalswift <practicalswift@users.noreply.github.com> | 2017-11-09 16:53:34 +0100 |
commit | 3e09b390b411298b9da8cc3f92132bfad15ac156 (patch) | |
tree | 034c464e339d74d67ee61f32ca23e82cb03b3d21 /src/test | |
parent | 86179897e230d8e5244fa7690ae1bc84b7958b9b (diff) |
Use MakeUnique<T>(...) instead of std::unique_ptr<T>(new T(...))
Diffstat (limited to 'src/test')
-rw-r--r-- | src/test/dbwrapper_tests.cpp | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/test/dbwrapper_tests.cpp b/src/test/dbwrapper_tests.cpp index d204e9236e..c1625cf476 100644 --- a/src/test/dbwrapper_tests.cpp +++ b/src/test/dbwrapper_tests.cpp @@ -125,7 +125,7 @@ BOOST_AUTO_TEST_CASE(existing_data_no_obfuscate) create_directories(ph); // Set up a non-obfuscated wrapper to write some initial data. - std::unique_ptr<CDBWrapper> dbw = std::unique_ptr<CDBWrapper>(new CDBWrapper(ph, (1 << 10), false, false, false)); + std::unique_ptr<CDBWrapper> dbw = MakeUnique<CDBWrapper>(ph, (1 << 10), false, false, false); char key = 'k'; uint256 in = InsecureRand256(); uint256 res; @@ -166,7 +166,7 @@ BOOST_AUTO_TEST_CASE(existing_data_reindex) create_directories(ph); // Set up a non-obfuscated wrapper to write some initial data. - std::unique_ptr<CDBWrapper> dbw = std::unique_ptr<CDBWrapper>(new CDBWrapper(ph, (1 << 10), false, false, false)); + std::unique_ptr<CDBWrapper> dbw = MakeUnique<CDBWrapper>(ph, (1 << 10), false, false, false); char key = 'k'; uint256 in = InsecureRand256(); uint256 res; |