mirror of
https://github.com/LBRYFoundation/pool.git
synced 2025-08-23 17:37:25 +00:00
stratum: also prepare normal optional mn+segwit
This commit is contained in:
parent
a78ec34d37
commit
fe47cca831
1 changed files with 2 additions and 1 deletions
|
@ -343,7 +343,7 @@ void coinbase_create(YAAMP_COIND *coind, YAAMP_JOB_TEMPLATE *templ, json_value *
|
|||
char script_dests[2048] = { 0 };
|
||||
char script_payee[128] = { 0 };
|
||||
char payees[4]; // addresses count
|
||||
int npayees = 1;
|
||||
int npayees = (templ->has_segwit_txs) ? 2 : 1;
|
||||
bool masternode_enabled = json_get_bool(json_result, "masternode_payments_enforced");
|
||||
bool superblocks_enabled = json_get_bool(json_result, "superblocks_enabled");
|
||||
json_value* superblock = json_get_array(json_result, "superblock");
|
||||
|
@ -378,6 +378,7 @@ void coinbase_create(YAAMP_COIND *coind, YAAMP_JOB_TEMPLATE *templ, json_value *
|
|||
}
|
||||
sprintf(payees, "%02x", npayees);
|
||||
strcat(templ->coinb2, payees);
|
||||
if (templ->has_segwit_txs) strcat(templ->coinb2, commitment);
|
||||
strcat(templ->coinb2, script_dests);
|
||||
job_pack_tx(coind, templ->coinb2, available, NULL);
|
||||
strcat(templ->coinb2, "00000000"); // locktime
|
||||
|
|
Loading…
Add table
Reference in a new issue