mirror of
https://github.com/dashpay/dash.git
synced 2024-12-27 04:52:59 +01:00
Remove/fix unused variables
This commit is contained in:
parent
b797fbd827
commit
a18707e397
@ -20,7 +20,6 @@
|
|||||||
|
|
||||||
const std::function<std::string(const char*)> G_TRANSLATION_FUN = nullptr;
|
const std::function<std::string(const char*)> G_TRANSLATION_FUN = nullptr;
|
||||||
|
|
||||||
static const int64_t DEFAULT_BENCH_EVALUATIONS = 5;
|
|
||||||
static const char* DEFAULT_BENCH_FILTER = ".*";
|
static const char* DEFAULT_BENCH_FILTER = ".*";
|
||||||
|
|
||||||
void InitBLSTests();
|
void InitBLSTests();
|
||||||
|
@ -86,8 +86,6 @@ public:
|
|||||||
ReceiveVvecs();
|
ReceiveVvecs();
|
||||||
size_t memberIdx = 0;
|
size_t memberIdx = 0;
|
||||||
bench.minEpochIterations(epoch_iters).run([&] {
|
bench.minEpochIterations(epoch_iters).run([&] {
|
||||||
auto& m = members[memberIdx];
|
|
||||||
|
|
||||||
ReceiveShares(memberIdx);
|
ReceiveShares(memberIdx);
|
||||||
|
|
||||||
std::set<size_t> invalidIndexes;
|
std::set<size_t> invalidIndexes;
|
||||||
|
@ -11,7 +11,6 @@
|
|||||||
#include <random.h>
|
#include <random.h>
|
||||||
|
|
||||||
|
|
||||||
static const int MIN_CORES = 2;
|
|
||||||
static const size_t BATCHES = 101;
|
static const size_t BATCHES = 101;
|
||||||
static const size_t BATCH_SIZE = 30;
|
static const size_t BATCH_SIZE = 30;
|
||||||
static const int PREVECTOR_SIZE = 28;
|
static const int PREVECTOR_SIZE = 28;
|
||||||
|
@ -2046,7 +2046,6 @@ bool AppInitMain()
|
|||||||
LogPrintf("* Using %.1fMiB for in-memory UTXO set (plus up to %.1fMiB of unused mempool space)\n", nCoinCacheUsage * (1.0 / 1024 / 1024), nMempoolSizeMax * (1.0 / 1024 / 1024));
|
LogPrintf("* Using %.1fMiB for in-memory UTXO set (plus up to %.1fMiB of unused mempool space)\n", nCoinCacheUsage * (1.0 / 1024 / 1024), nMempoolSizeMax * (1.0 / 1024 / 1024));
|
||||||
|
|
||||||
bool fLoaded = false;
|
bool fLoaded = false;
|
||||||
int64_t nStart = GetTimeMillis();
|
|
||||||
|
|
||||||
while (!fLoaded && !ShutdownRequested()) {
|
while (!fLoaded && !ShutdownRequested()) {
|
||||||
bool fReset = fReindex;
|
bool fReset = fReindex;
|
||||||
|
@ -925,7 +925,7 @@ bool CBlockPolicyEstimator::Read(CAutoFile& filein)
|
|||||||
try {
|
try {
|
||||||
LOCK(cs_feeEstimator);
|
LOCK(cs_feeEstimator);
|
||||||
int nVersionRequired, nVersionThatWrote;
|
int nVersionRequired, nVersionThatWrote;
|
||||||
unsigned int nFileBestSeenHeight, nFileHistoricalFirst, nFileHistoricalBest;
|
unsigned int nFileBestSeenHeight;
|
||||||
filein >> nVersionRequired >> nVersionThatWrote;
|
filein >> nVersionRequired >> nVersionThatWrote;
|
||||||
if (nVersionRequired > CLIENT_VERSION)
|
if (nVersionRequired > CLIENT_VERSION)
|
||||||
return error("CBlockPolicyEstimator::Read(): up-version (%d) fee estimate file", nVersionRequired);
|
return error("CBlockPolicyEstimator::Read(): up-version (%d) fee estimate file", nVersionRequired);
|
||||||
|
@ -481,7 +481,6 @@ void CoinControlDialog::updateLabels(CCoinControl& m_coin_control, WalletModel *
|
|||||||
unsigned int nBytes = 0;
|
unsigned int nBytes = 0;
|
||||||
unsigned int nBytesInputs = 0;
|
unsigned int nBytesInputs = 0;
|
||||||
unsigned int nQuantity = 0;
|
unsigned int nQuantity = 0;
|
||||||
int nQuantityUncompressed = 0;
|
|
||||||
bool fUnselectedSpent{false};
|
bool fUnselectedSpent{false};
|
||||||
bool fUnselectedNonMixed{false};
|
bool fUnselectedNonMixed{false};
|
||||||
|
|
||||||
|
@ -42,9 +42,8 @@ void NetworkStyle::rotateColor(QColor& col, const int iconColorHueShift, const i
|
|||||||
col.setHsl(h,s,l,a);
|
col.setHsl(h,s,l,a);
|
||||||
}
|
}
|
||||||
|
|
||||||
void NetworkStyle::rotateColors(QImage& img, const int iconColorHueShift, const int iconColorSaturationReduction) {
|
void NetworkStyle::rotateColors(QImage& img, const int iconColorHueShift, const int iconColorSaturationReduction)
|
||||||
int h,s,l,a;
|
{
|
||||||
|
|
||||||
// traverse though lines
|
// traverse though lines
|
||||||
for(int y=0;y<img.height();y++)
|
for(int y=0;y<img.height();y++)
|
||||||
{
|
{
|
||||||
|
@ -162,7 +162,7 @@ void WalletFrame::gotoSendCoinsPage(QString addr)
|
|||||||
void WalletFrame::gotoCoinJoinCoinsPage(QString addr)
|
void WalletFrame::gotoCoinJoinCoinsPage(QString addr)
|
||||||
{
|
{
|
||||||
QMap<QString, WalletView*>::const_iterator i;
|
QMap<QString, WalletView*>::const_iterator i;
|
||||||
for (auto i = mapWalletViews.constBegin(); i != mapWalletViews.constEnd(); ++i) {
|
for (i = mapWalletViews.constBegin(); i != mapWalletViews.constEnd(); ++i) {
|
||||||
i.value()->gotoCoinJoinCoinsPage(addr);
|
i.value()->gotoCoinJoinCoinsPage(addr);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -63,7 +63,6 @@ struct mt_pooled_secure_allocator : public std::allocator<T> {
|
|||||||
private:
|
private:
|
||||||
size_t get_bucket()
|
size_t get_bucket()
|
||||||
{
|
{
|
||||||
auto tid = std::this_thread::get_id();
|
|
||||||
size_t x = std::hash<std::thread::id>{}(std::this_thread::get_id());
|
size_t x = std::hash<std::thread::id>{}(std::this_thread::get_id());
|
||||||
return x % pools.size();
|
return x % pools.size();
|
||||||
}
|
}
|
||||||
|
@ -517,7 +517,6 @@ BOOST_FIXTURE_TEST_CASE(dip3_test_mempool_reorg, TestChainDIP3Setup)
|
|||||||
|
|
||||||
BOOST_FIXTURE_TEST_CASE(dip3_test_mempool_dual_proregtx, TestChainDIP3Setup)
|
BOOST_FIXTURE_TEST_CASE(dip3_test_mempool_dual_proregtx, TestChainDIP3Setup)
|
||||||
{
|
{
|
||||||
int nHeight = chainActive.Height();
|
|
||||||
auto utxos = BuildSimpleUtxoMap(m_coinbase_txns);
|
auto utxos = BuildSimpleUtxoMap(m_coinbase_txns);
|
||||||
|
|
||||||
// Create a MN
|
// Create a MN
|
||||||
|
@ -693,8 +693,6 @@ static bool AcceptToMemoryPoolWorker(const CChainParams& chainparams, CTxMemPool
|
|||||||
auto itConflicting = pool.mapNextTx.find(txin.prevout);
|
auto itConflicting = pool.mapNextTx.find(txin.prevout);
|
||||||
if (itConflicting != pool.mapNextTx.end())
|
if (itConflicting != pool.mapNextTx.end())
|
||||||
{
|
{
|
||||||
const CTransaction *ptxConflicting = itConflicting->second;
|
|
||||||
|
|
||||||
// Transaction conflicts with mempool and RBF doesn't exist in Dash
|
// Transaction conflicts with mempool and RBF doesn't exist in Dash
|
||||||
return state.Invalid(false, REJECT_DUPLICATE, "txn-mempool-conflict");
|
return state.Invalid(false, REJECT_DUPLICATE, "txn-mempool-conflict");
|
||||||
}
|
}
|
||||||
@ -824,7 +822,7 @@ static bool AcceptToMemoryPoolWorker(const CChainParams& chainparams, CTxMemPool
|
|||||||
// Check against previous transactions
|
// Check against previous transactions
|
||||||
// This is done last to help prevent CPU exhaustion denial-of-service attacks.
|
// This is done last to help prevent CPU exhaustion denial-of-service attacks.
|
||||||
PrecomputedTransactionData txdata(tx);
|
PrecomputedTransactionData txdata(tx);
|
||||||
if (!CheckInputs(tx, state, view, true, STANDARD_SCRIPT_VERIFY_FLAGS, true, false, txdata))
|
if (!CheckInputs(tx, state, view, true, scriptVerifyFlags, true, false, txdata))
|
||||||
return false; // state filled in by CheckInputs
|
return false; // state filled in by CheckInputs
|
||||||
|
|
||||||
// Check again against the current block tip's script verification
|
// Check again against the current block tip's script verification
|
||||||
@ -1235,7 +1233,6 @@ bool IsInitialBlockDownload()
|
|||||||
return false;
|
return false;
|
||||||
if (fImporting || fReindex)
|
if (fImporting || fReindex)
|
||||||
return true;
|
return true;
|
||||||
const CChainParams& chainParams = Params();
|
|
||||||
if (chainActive.Tip() == nullptr)
|
if (chainActive.Tip() == nullptr)
|
||||||
return true;
|
return true;
|
||||||
if (chainActive.Tip()->nChainWork < nMinimumChainWork)
|
if (chainActive.Tip()->nChainWork < nMinimumChainWork)
|
||||||
|
@ -5530,8 +5530,6 @@ void CMerkleTx::SetMerkleBranch(const CBlockIndex* pindex, int posInBlock)
|
|||||||
|
|
||||||
int CMerkleTx::GetDepthInMainChain() const
|
int CMerkleTx::GetDepthInMainChain() const
|
||||||
{
|
{
|
||||||
int nResult;
|
|
||||||
|
|
||||||
if (hashUnset())
|
if (hashUnset())
|
||||||
return 0;
|
return 0;
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user