mirror of
https://git.wownero.com/wownero/wownero.git
synced 2024-08-15 01:03:23 +00:00
Restore pool mining
This commit is contained in:
parent
87f1d448bd
commit
009814647a
7 changed files with 7 additions and 6 deletions
|
@ -470,7 +470,7 @@ namespace cryptonote
|
||||||
VARINT_FIELD(timestamp)
|
VARINT_FIELD(timestamp)
|
||||||
FIELD(prev_id)
|
FIELD(prev_id)
|
||||||
FIELD(nonce)
|
FIELD(nonce)
|
||||||
if (major_version >= BLOCK_HEADER_MINER_SIG)
|
if (major_version >= BLOCK_HEADER_MINER_SIG && major_version < REMOVED_BLOCK_HEADER_MINER_SIG)
|
||||||
{
|
{
|
||||||
FIELD(signature)
|
FIELD(signature)
|
||||||
FIELD(vote)
|
FIELD(vote)
|
||||||
|
|
|
@ -196,7 +196,7 @@ namespace boost
|
||||||
a & b.timestamp;
|
a & b.timestamp;
|
||||||
a & b.prev_id;
|
a & b.prev_id;
|
||||||
a & b.nonce;
|
a & b.nonce;
|
||||||
if (b.major_version >= BLOCK_HEADER_MINER_SIG)
|
if (b.major_version >= BLOCK_HEADER_MINER_SIG && b.major_version < REMOVED_BLOCK_HEADER_MINER_SIG)
|
||||||
{
|
{
|
||||||
a & b.signature;
|
a & b.signature;
|
||||||
a & b.vote;
|
a & b.vote;
|
||||||
|
|
|
@ -609,7 +609,7 @@ namespace cryptonote
|
||||||
b.nonce = nonce;
|
b.nonce = nonce;
|
||||||
|
|
||||||
// Miner Block Header Signing
|
// Miner Block Header Signing
|
||||||
if (b.major_version >= BLOCK_HEADER_MINER_SIG)
|
if (b.major_version >= BLOCK_HEADER_MINER_SIG && b.major_version < REMOVED_BLOCK_HEADER_MINER_SIG)
|
||||||
{
|
{
|
||||||
// tx key derivation
|
// tx key derivation
|
||||||
crypto::key_derivation derivation;
|
crypto::key_derivation derivation;
|
||||||
|
|
|
@ -46,6 +46,7 @@
|
||||||
#define CURRENT_BLOCK_MAJOR_VERSION 7
|
#define CURRENT_BLOCK_MAJOR_VERSION 7
|
||||||
#define CURRENT_BLOCK_MINOR_VERSION 7
|
#define CURRENT_BLOCK_MINOR_VERSION 7
|
||||||
#define BLOCK_HEADER_MINER_SIG 18
|
#define BLOCK_HEADER_MINER_SIG 18
|
||||||
|
#define REMOVED_BLOCK_HEADER_MINER_SIG 20
|
||||||
#define CRYPTONOTE_BLOCK_FUTURE_TIME_LIMIT_V2 300*2
|
#define CRYPTONOTE_BLOCK_FUTURE_TIME_LIMIT_V2 300*2
|
||||||
#define CRYPTONOTE_BLOCK_FUTURE_TIME_LIMIT 60*60*2
|
#define CRYPTONOTE_BLOCK_FUTURE_TIME_LIMIT 60*60*2
|
||||||
#define CRYPTONOTE_DEFAULT_TX_SPENDABLE_AGE 4
|
#define CRYPTONOTE_DEFAULT_TX_SPENDABLE_AGE 4
|
||||||
|
|
|
@ -1392,7 +1392,7 @@ difficulty_type Blockchain::get_next_difficulty_for_alternative_chain(const std:
|
||||||
bool Blockchain::prevalidate_miner_transaction(const block& b, uint64_t height, uint8_t hf_version)
|
bool Blockchain::prevalidate_miner_transaction(const block& b, uint64_t height, uint8_t hf_version)
|
||||||
{
|
{
|
||||||
// Miner Block Header Signing
|
// Miner Block Header Signing
|
||||||
if (hf_version >= BLOCK_HEADER_MINER_SIG)
|
if (hf_version >= BLOCK_HEADER_MINER_SIG && hf_version < REMOVED_BLOCK_HEADER_MINER_SIG)
|
||||||
{
|
{
|
||||||
// sanity checks
|
// sanity checks
|
||||||
if (b.miner_tx.vout.size() != 1)
|
if (b.miner_tx.vout.size() != 1)
|
||||||
|
|
|
@ -2192,7 +2192,7 @@ namespace cryptonote
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
b.nonce = req.starting_nonce;
|
b.nonce = req.starting_nonce;
|
||||||
if (b.major_version >= BLOCK_HEADER_MINER_SIG)
|
if (b.major_version >= BLOCK_HEADER_MINER_SIG && b.major_version < REMOVED_BLOCK_HEADER_MINER_SIG)
|
||||||
{
|
{
|
||||||
b.signature = {};
|
b.signature = {};
|
||||||
b.vote = 0;
|
b.vote = 0;
|
||||||
|
|
|
@ -895,7 +895,7 @@ namespace rpc
|
||||||
header.minor_version = b.minor_version;
|
header.minor_version = b.minor_version;
|
||||||
header.timestamp = b.timestamp;
|
header.timestamp = b.timestamp;
|
||||||
header.nonce = b.nonce;
|
header.nonce = b.nonce;
|
||||||
if (b.major_version >= BLOCK_HEADER_MINER_SIG)
|
if (b.major_version >= BLOCK_HEADER_MINER_SIG && b.major_version < REMOVED_BLOCK_HEADER_MINER_SIG)
|
||||||
{
|
{
|
||||||
header.signature = b.signature;
|
header.signature = b.signature;
|
||||||
header.vote = b.vote;
|
header.vote = b.vote;
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue