Added Loki support
This commit is contained in:
@@ -8,4 +8,5 @@ enum BLOB_TYPE {
|
|||||||
BLOB_TYPE_FORKNOTE2 = 2,
|
BLOB_TYPE_FORKNOTE2 = 2,
|
||||||
BLOB_TYPE_CRYPTONOTE2 = 3, // Masari
|
BLOB_TYPE_CRYPTONOTE2 = 3, // Masari
|
||||||
BLOB_TYPE_CRYPTONOTE_RYO = 4, // Ryo
|
BLOB_TYPE_CRYPTONOTE_RYO = 4, // Ryo
|
||||||
|
BLOB_TYPE_CRYPTONOTE_LOKI = 5, // Loki
|
||||||
};
|
};
|
||||||
@@ -151,8 +151,16 @@ namespace cryptonote
|
|||||||
//extra
|
//extra
|
||||||
std::vector<uint8_t> extra;
|
std::vector<uint8_t> extra;
|
||||||
|
|
||||||
|
std::vector<uint64_t> output_unlock_times;
|
||||||
|
bool is_deregister;
|
||||||
|
|
||||||
BEGIN_SERIALIZE()
|
BEGIN_SERIALIZE()
|
||||||
VARINT_FIELD(version)
|
VARINT_FIELD(version)
|
||||||
|
if (blob_type == BLOB_TYPE_CRYPTONOTE_LOKI)
|
||||||
|
{
|
||||||
|
FIELD(output_unlock_times)
|
||||||
|
FIELD(is_deregister)
|
||||||
|
}
|
||||||
VARINT_FIELD(unlock_time)
|
VARINT_FIELD(unlock_time)
|
||||||
FIELD(vin)
|
FIELD(vin)
|
||||||
FIELD(vout)
|
FIELD(vout)
|
||||||
|
|||||||
@@ -45,6 +45,13 @@ inline bool do_serialize(Archive &ar, T &v)
|
|||||||
return ::serializer<Archive, T>::serialize(ar, v);
|
return ::serializer<Archive, T>::serialize(ar, v);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
template <class Archive>
|
||||||
|
inline bool do_serialize(Archive &ar, bool &v)
|
||||||
|
{
|
||||||
|
ar.serialize_blob(&v, sizeof(v));
|
||||||
|
return true;
|
||||||
|
}
|
||||||
|
|
||||||
#ifndef __GNUC__
|
#ifndef __GNUC__
|
||||||
#ifndef constexpr
|
#ifndef constexpr
|
||||||
#define constexpr
|
#define constexpr
|
||||||
|
|||||||
Reference in New Issue
Block a user