Skip to content

Commit 9fe6ac4

Browse files
committed
ci: various linter / CI compiler error fixes
Includes changing TRUE to OP_TRUE for anyone-can-spend output name, to avoid symbol conflict on win64 builds, which is really obnoxious.
1 parent 60a2d22 commit 9fe6ac4

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

42 files changed

+133
-117
lines changed

contrib/assets_tutorial/test_framework/authproxy.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -166,7 +166,7 @@ def _batch(self, rpc_call_list):
166166
def _get_response(self):
167167
try:
168168
http_response = self.__conn.getresponse()
169-
except socket.timeout as e:
169+
except socket.timeout:
170170
raise JSONRPCException({
171171
'code': -344,
172172
'message': '%r RPC took longer than %f seconds. Consider '

src/httpserver.cpp

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,6 @@
2424

2525
#include <sys/types.h>
2626
#include <sys/stat.h>
27-
#include <deque>
2827

2928
#include <event2/thread.h>
3029
#include <event2/buffer.h>

src/init.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2093,7 +2093,7 @@ bool AppInitMain(const util::Ref& context, NodeContext& node, interfaces::BlockA
20932093
CScheduler::Function reevaluationLoop = [&node]{ node.reverification_scheduler->serviceQueue(); };
20942094
threadGroup.create_thread(std::bind(&TraceThread<CScheduler::Function>, "reevaluation_scheduler", reevaluationLoop));
20952095

2096-
CScheduler::Function f2 = boost::bind(&MainchainRPCCheck, false);
2096+
CScheduler::Function f2 = std::bind(&MainchainRPCCheck, false);
20972097
unsigned int check_rpc_every = gArgs.GetArg("-recheckpeginblockinterval", 120);
20982098
if (check_rpc_every) {
20992099
node.reverification_scheduler->scheduleEvery(f2, std::chrono::seconds(check_rpc_every));

src/pegins.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -456,7 +456,7 @@ std::vector<std::pair<CScript, CScript>> GetValidFedpegScripts(const CBlockIndex
456456

457457
std::vector<std::pair<CScript, CScript>> fedpegscripts;
458458

459-
const int32_t epoch_length = params.dynamic_epoch_length;
459+
const int32_t epoch_length = (int32_t) params.dynamic_epoch_length;
460460
const int32_t epoch_age = pblockindex->nHeight % epoch_length;
461461
const int32_t epoch_start_height = pblockindex->nHeight - epoch_age;
462462

src/primitives/block.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -38,7 +38,7 @@ class CProof
3838
if (!(s.GetType() & SER_GETHASH))
3939
s >> *(CScriptBase*)(&solution);
4040
}
41-
41+
4242
void SetNull()
4343
{
4444
challenge.clear();

src/qt/bitcoinamountfield.cpp

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,6 @@
88
#include <qt/guiconstants.h>
99
#include <qt/guiutil.h>
1010
#include <qt/qvaluecombobox.h>
11-
#include <qt/guiutil.h>
1211

1312
#include <assetsdir.h>
1413
#include <chainparams.h>

src/qt/qrimagewidget.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -67,7 +67,7 @@ bool QRImageWidget::setQR(const QString& data, const QString& text)
6767

6868
// Elements: Hack to get QR address to print right
6969
const size_t MORE_WIDTH = 80;
70-
70+
7171
const int qr_image_size = QR_IMAGE_SIZE + MORE_WIDTH + (text.isEmpty() ? 0 : 2 * QR_IMAGE_MARGIN);
7272
QImage qrAddrImage(qr_image_size, qr_image_size, QImage::Format_RGB32);
7373
qrAddrImage.fill(0xffffff);

src/script/sign.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -178,7 +178,7 @@ static bool SignStep(const SigningProvider& provider, const BaseSignatureCreator
178178
sigdata.missing_witness_script = uint256(vSolutions[0]);
179179
return false;
180180

181-
case TxoutType::TRUE:
181+
case TxoutType::OP_TRUE:
182182
return Params().anyonecanspend_aremine;
183183

184184
default:

src/script/standard.cpp

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -69,7 +69,7 @@ std::string GetTxnOutputType(TxoutType t)
6969
case TxoutType::WITNESS_V0_SCRIPTHASH: return "witness_v0_scripthash";
7070
case TxoutType::WITNESS_V1_TAPROOT: return "witness_v1_taproot";
7171
case TxoutType::WITNESS_UNKNOWN: return "witness_unknown";
72-
case TxoutType::TRUE: return "true";
72+
case TxoutType::OP_TRUE: return "true";
7373
case TxoutType::FEE: return "fee";
7474
}
7575
assert(false);
@@ -126,7 +126,7 @@ TxoutType Solver(const CScript& scriptPubKey, std::vector<std::vector<unsigned c
126126
vSolutionsRet.clear();
127127

128128
if (Params().anyonecanspend_aremine && scriptPubKey == CScript() << OP_TRUE) {
129-
return TxoutType::TRUE;
129+
return TxoutType::OP_TRUE;
130130
}
131131

132132
// Fee outputs are for elements-style transactions only

src/script/standard.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -146,7 +146,7 @@ enum class TxoutType {
146146
WITNESS_V0_KEYHASH,
147147
WITNESS_V1_TAPROOT,
148148
WITNESS_UNKNOWN, //!< Only for Witness versions not already defined above
149-
TRUE, // For testing purposes only
149+
OP_TRUE, // For testing purposes only
150150
// ELEMENTS:
151151
FEE,
152152
};

0 commit comments

Comments
 (0)