forked from lthn/blockchain
wallet resync-on-load issue fixed (the bug was in data storing on Boost > 69), also Zano made compatible with Boost 1.72
This commit is contained in:
parent
5fa0e15843
commit
bb6dea509e
4 changed files with 3 additions and 7 deletions
|
|
@ -340,7 +340,7 @@ namespace eos {
|
|||
// we choose to use little endian because this way we just
|
||||
// save the first size bytes to the stream and skip the rest
|
||||
#if BOOST_VERSION >= 106900
|
||||
temp = endian::native_to_little(temp);
|
||||
temp = endian::native_to_little(t);
|
||||
#else
|
||||
endian::store_little_endian<T, sizeof(T)>(&temp, t);
|
||||
#endif
|
||||
|
|
|
|||
|
|
@ -67,7 +67,6 @@ POP_VS_WARNINGS
|
|||
#include <boost/serialization/vector.hpp>
|
||||
#include <boost/serialization/version.hpp>
|
||||
#include <boost/spirit/home/support/detail/endian/endian.hpp>
|
||||
#include <boost/spirit/home/support/detail/math/fpclassify.hpp>
|
||||
#include <boost/thread.hpp>
|
||||
#include <boost/timer/timer.hpp>
|
||||
#include <boost/type_traits/is_arithmetic.hpp>
|
||||
|
|
|
|||
|
|
@ -2389,10 +2389,6 @@ bool wallet2::deinit()
|
|||
bool wallet2::clear()
|
||||
{
|
||||
reset_all();
|
||||
//currency::block b;
|
||||
//currency::generate_genesis_block(b);
|
||||
m_chain.clear();
|
||||
//m_blockchain.push_back(get_block_hash(b));
|
||||
return true;
|
||||
}
|
||||
//----------------------------------------------------------------------------------------------------
|
||||
|
|
@ -2666,6 +2662,7 @@ void wallet2::load(const std::wstring& wallet_, const std::string& password)
|
|||
bool need_to_resync = false;
|
||||
if (wbh.m_ver == 1000)
|
||||
{
|
||||
// old WALLET_FILE_BINARY_HEADER_VERSION version means no encryption
|
||||
need_to_resync = !tools::portable_unserialize_obj_from_stream(*this, data_file);
|
||||
}
|
||||
else
|
||||
|
|
|
|||
|
|
@ -707,7 +707,7 @@ namespace tools
|
|||
|
||||
if (ver < 149)
|
||||
{
|
||||
WLT_LOG_MAGENTA("Wallet file truncated due to old version", LOG_LEVEL_0);
|
||||
WLT_LOG_MAGENTA("Wallet file truncated due to old version: " << ver, LOG_LEVEL_0);
|
||||
return;
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue