mirror of
https://github.com/ElementsProject/elements.git
synced 2026-08-14 12:43:40 +02:00
Move {Get,Set}Compact from bignum to uint256
This commit is contained in:
parent
a7031507e6
commit
df9eb5e14f
13 changed files with 243 additions and 199 deletions
|
|
@ -363,7 +363,7 @@ Value getwork(const Array& params, bool fHelp)
|
|||
char phash1[64];
|
||||
FormatHashBuffers(pblock, pmidstate, pdata, phash1);
|
||||
|
||||
uint256 hashTarget = CBigNum().SetCompact(pblock->nBits).getuint256();
|
||||
uint256 hashTarget = uint256().SetCompact(pblock->nBits);
|
||||
|
||||
Object result;
|
||||
result.push_back(Pair("midstate", HexStr(BEGIN(pmidstate), END(pmidstate)))); // deprecated
|
||||
|
|
@ -559,7 +559,7 @@ Value getblocktemplate(const Array& params, bool fHelp)
|
|||
Object aux;
|
||||
aux.push_back(Pair("flags", HexStr(COINBASE_FLAGS.begin(), COINBASE_FLAGS.end())));
|
||||
|
||||
uint256 hashTarget = CBigNum().SetCompact(pblock->nBits).getuint256();
|
||||
uint256 hashTarget = uint256().SetCompact(pblock->nBits);
|
||||
|
||||
static Array aMutable;
|
||||
if (aMutable.empty())
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue