Update CMakeLists.txt - play with openssl
[novacoin.git] / src / base58.cpp
index e8cde34..b077a0b 100644 (file)
@@ -14,8 +14,7 @@
 //
 
 #include "base58.h"
-#include "key.h"
-#include "script.h"
+#include "hash.h"
 
 static const std::array<char, 58> digits = {
     '1', '2', '3', '4', '5', '6', '7', '8', '9', 'A', 'B', 'C', 'D', 'E', 'F',
@@ -259,7 +258,7 @@ bool DecodeBase58Check(const std::string& str, std::vector<unsigned char>& vchRe
 
     std::string CBase58Data::ToString() const
     {
-        std::vector<unsigned char> vch(1, nVersion);
+        std::vector<unsigned char> vch{nVersion};
         vch.insert(vch.end(), vchData.begin(), vchData.end());
         return EncodeBase58Check(vch);
     }
@@ -274,7 +273,7 @@ bool DecodeBase58Check(const std::string& str, std::vector<unsigned char>& vchRe
     }
 
     namespace {
-        class CBitcoinAddressVisitor : public boost::static_visitor<bool> {
+        class CBitcoinAddressVisitor {
         private:
             CBitcoinAddress *addr;
         public:
@@ -299,7 +298,7 @@ bool DecodeBase58Check(const std::string& str, std::vector<unsigned char>& vchRe
 
     bool CBitcoinAddress::Set(const CTxDestination &dest)
     {
-        return boost::apply_visitor(CBitcoinAddressVisitor(this), dest);
+        return std::visit(CBitcoinAddressVisitor(this), dest);
     }
 
     bool CBitcoinAddress::Set(const CMalleablePubKey &mpk) {