From 648f6954f42b2061e846969e604231d6d07c9afc Mon Sep 17 00:00:00 2001 From: sowle Date: Thu, 11 Jul 2024 21:21:22 +0200 Subject: [PATCH 1/3] wallet: allow to burn an asset up to zero --- src/wallet/wallet2.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/wallet/wallet2.cpp b/src/wallet/wallet2.cpp index a9d12d24..d56be799 100644 --- a/src/wallet/wallet2.cpp +++ b/src/wallet/wallet2.cpp @@ -5420,7 +5420,7 @@ void wallet2::burn_asset(const crypto::public_key asset_id, uint64_t amount_to_b asset_descriptor_operation asset_burn_info = AUTO_VAL_INIT(asset_burn_info); asset_burn_info.descriptor = rsp.asset_descriptor; - CHECK_AND_ASSERT_THROW_MES(asset_burn_info.descriptor.current_supply > amount_to_burn, "Wrong amount to burn (current_supply" << asset_burn_info.descriptor.current_supply << " is less then " << amount_to_burn << ")"); + CHECK_AND_ASSERT_THROW_MES(asset_burn_info.descriptor.current_supply >= amount_to_burn, "Wrong amount to burn (current_supply" << asset_burn_info.descriptor.current_supply << " is less then " << amount_to_burn << ")"); currency::tx_destination_entry dst_to_burn = AUTO_VAL_INIT(dst_to_burn); dst_to_burn.amount = amount_to_burn; From 156c96fc4222d8aa89f66f59322dd81fbcffa320 Mon Sep 17 00:00:00 2001 From: sowle Date: Thu, 11 Jul 2024 21:32:18 +0200 Subject: [PATCH 2/3] minor bugfix in print_asset_info() --- src/daemon/daemon_commands_handler.h | 1 + 1 file changed, 1 insertion(+) diff --git a/src/daemon/daemon_commands_handler.h b/src/daemon/daemon_commands_handler.h index 8f2aa24a..c960a39c 100644 --- a/src/daemon/daemon_commands_handler.h +++ b/src/daemon/daemon_commands_handler.h @@ -817,6 +817,7 @@ private: " amount cmt * 1/8: " << aop.amount_commitment << ENDL << " hidden supply: " << (aop.descriptor.hidden_supply ? "yes" : "no") << ENDL << ""; + ++idx; } LOG_PRINT_L0(ss.str()); From 45eeb8c5f9c1c4ae1a0d09ff3244e5348debba82 Mon Sep 17 00:00:00 2001 From: zano build machine Date: Thu, 11 Jul 2024 22:34:29 +0300 Subject: [PATCH 3/3] === build number: 332 -> 333 === --- src/version.h.in | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/version.h.in b/src/version.h.in index ed1084e5..f1d6cbf4 100644 --- a/src/version.h.in +++ b/src/version.h.in @@ -8,6 +8,6 @@ #define PROJECT_REVISION "0" #define PROJECT_VERSION PROJECT_MAJOR_VERSION "." PROJECT_MINOR_VERSION "." PROJECT_REVISION -#define PROJECT_VERSION_BUILD_NO 332 +#define PROJECT_VERSION_BUILD_NO 333 #define PROJECT_VERSION_BUILD_NO_STR STRINGIFY_EXPAND(PROJECT_VERSION_BUILD_NO) #define PROJECT_VERSION_LONG PROJECT_VERSION "." PROJECT_VERSION_BUILD_NO_STR "[" BUILD_COMMIT_ID "]"