diff --git a/src/crypto/crypto-sugar.h b/src/crypto/crypto-sugar.h index b708283f..be99731f 100644 --- a/src/crypto/crypto-sugar.h +++ b/src/crypto/crypto-sugar.h @@ -1043,7 +1043,7 @@ namespace crypto void zero() { PUSH_GCC_WARNINGS - DISABLE_GCC_AND_CLANG_WARNING(class-memaccess) + DISABLE_GCC_WARNING(class-memaccess) size_t size_bytes = sizeof(scalar_t) * size(); memset(data(), 0, size_bytes); POP_GCC_WARNINGS diff --git a/src/wallet/wallet2.h b/src/wallet/wallet2.h index c10892ea..aae4d6fd 100644 --- a/src/wallet/wallet2.h +++ b/src/wallet/wallet2.h @@ -1096,7 +1096,6 @@ namespace tools ts_middle -= ts_middle % POS_SCAN_STEP; uint64_t ts_window = std::min(ts_middle - ts_from, ts_to - ts_middle); - size_t pos_entry_index = 0; for (size_t transfer_index = 0; transfer_index != m_transfers.size(); transfer_index++) { auto& tr = m_transfers[transfer_index]; @@ -1164,7 +1163,6 @@ namespace tools next_turn(); } - ++pos_entry_index; } cxt.status = API_RETURN_CODE_NOT_FOUND; return false; diff --git a/src/wallet/wallet_rpc_server.cpp b/src/wallet/wallet_rpc_server.cpp index 8b75bfd2..9a8dd1d1 100644 --- a/src/wallet/wallet_rpc_server.cpp +++ b/src/wallet/wallet_rpc_server.cpp @@ -816,9 +816,10 @@ namespace tools res.amount_swept = 0; res.bare_outs_swept = 0; res.fee_spent = 0; - res.txs_sent = 0; - w.get_wallet()->sweep_bare_unspent_outputs(w.get_wallet()->get_account().get_public_address(), groups, static_cast(res.txs_sent), res.amount_swept, res.fee_spent, res.bare_outs_swept); + size_t txs_sent = 0; + w.get_wallet()->sweep_bare_unspent_outputs(w.get_wallet()->get_account().get_public_address(), groups, txs_sent, res.amount_swept, res.fee_spent, res.bare_outs_swept); + res.txs_sent = txs_sent; return true; WALLET_RPC_CATCH_TRY_ENTRY();