From 53d14fc615abd664781af98f8b9992cde4268ad3 Mon Sep 17 00:00:00 2001 From: Czarek Nakamoto Date: Wed, 3 Jan 2024 14:11:19 +0100 Subject: [PATCH] prepare for sweep --- libbridge/src/main/cpp/wallet2_api_c.cpp | 6 +++++- libbridge/src/main/cpp/wallet2_api_c.h | 2 +- 2 files changed, 6 insertions(+), 2 deletions(-) diff --git a/libbridge/src/main/cpp/wallet2_api_c.cpp b/libbridge/src/main/cpp/wallet2_api_c.cpp index 6faa922..97b6fa8 100644 --- a/libbridge/src/main/cpp/wallet2_api_c.cpp +++ b/libbridge/src/main/cpp/wallet2_api_c.cpp @@ -1109,8 +1109,12 @@ void* MONERO_Wallet_createTransaction(void* wallet_ptr, const char* dst_addr, co int pendingTransactionPriority, uint32_t subaddr_account) { Monero::Wallet *wallet = reinterpret_cast(wallet_ptr); + Monero::optional optAmount; + if (amount != 0) { + optAmount = amount; + } return wallet->createTransaction(std::string(dst_addr), std::string(payment_id), - amount, mixin_count, + optAmount, mixin_count, Monero::PendingTransaction::Priority_Low, subaddr_account /*, subaddr_indices */); } diff --git a/libbridge/src/main/cpp/wallet2_api_c.h b/libbridge/src/main/cpp/wallet2_api_c.h index e38c51b..6e9c971 100644 --- a/libbridge/src/main/cpp/wallet2_api_c.h +++ b/libbridge/src/main/cpp/wallet2_api_c.h @@ -573,7 +573,7 @@ uint64_t MONERO_Wallet_estimateBlockChainHeight(void* wallet_ptr); // virtual uint64_t daemonBlockChainHeight() const = 0; uint64_t MONERO_Wallet_daemonBlockChainHeight(void* wallet_ptr); uint64_t MONERO_Wallet_daemonBlockChainHeight_cached(void* wallet_ptr); -bool MONERO_Wallet_daemonBlockChainHeight_enableRefresh(void* wallet_ptr, int seconds); +void MONERO_Wallet_daemonBlockChainHeight_runThread(void* wallet_ptr, int seconds); // virtual uint64_t daemonBlockChainTargetHeight() const = 0; uint64_t MONERO_Wallet_daemonBlockChainTargetHeight(void* wallet_ptr); // virtual bool synchronized() const = 0;