Fixed cppcheck errors

This commit is contained in:
SChernykh 2024-02-25 00:48:51 +01:00
parent 45dabd8ddb
commit d4a3bc0e20
3 changed files with 7 additions and 3 deletions

View file

@ -27,7 +27,7 @@ class MergeMiningClientJSON_RPC : public IMergeMiningClient
{ {
public: public:
MergeMiningClientJSON_RPC(p2pool* pool, const std::string& host, const std::string& wallet); MergeMiningClientJSON_RPC(p2pool* pool, const std::string& host, const std::string& wallet);
~MergeMiningClientJSON_RPC(); ~MergeMiningClientJSON_RPC() override;
bool get_params(ChainParameters& out_params) const override; bool get_params(ChainParameters& out_params) const override;
void submit_solution(const std::vector<uint8_t>& blob, const std::vector<hash>& merkle_proof) override; void submit_solution(const std::vector<uint8_t>& blob, const std::vector<hash>& merkle_proof) override;

View file

@ -185,7 +185,11 @@ void MergeMiningClientTari::run()
} }
} }
LOGINFO(6, "Tari height = " << response2.block().header().height()); LOGINFO(6, "Tari block template: height = " << response.new_block_template().header().height()
<< ", diff = " << response.miner_data().target_difficulty()
<< ", reward = " << response.miner_data().reward()
<< ", fees = " << response.miner_data().total_fees()
);
const int64_t timeout = std::max<int64_t>(500'000'000 - duration_cast<nanoseconds>(high_resolution_clock::now() - t1).count(), 1'000'000); const int64_t timeout = std::max<int64_t>(500'000'000 - duration_cast<nanoseconds>(high_resolution_clock::now() - t1).count(), 1'000'000);

View file

@ -28,7 +28,7 @@ class MergeMiningClientTari : public IMergeMiningClient, public nocopy_nomove
{ {
public: public:
MergeMiningClientTari(p2pool* pool, std::string host, const std::string& wallet); MergeMiningClientTari(p2pool* pool, std::string host, const std::string& wallet);
~MergeMiningClientTari(); ~MergeMiningClientTari() override;
bool get_params(ChainParameters& out_params) const override; bool get_params(ChainParameters& out_params) const override;
void submit_solution(const std::vector<uint8_t>& blob, const std::vector<hash>& merkle_proof) override; void submit_solution(const std::vector<uint8_t>& blob, const std::vector<hash>& merkle_proof) override;