From e3a81e3902178a8bf008f5727c0f0fee6f666f86 Mon Sep 17 00:00:00 2001 From: Uncle Stinky Date: Fri, 9 Oct 2026 15:23:20 +0300 Subject: [PATCH] https://ghostforum.org/t/bounty-of-100-encodes-as-0-in-evm-calldata-as-u32-wrap/133 Signed-off-by: Uncle Stinky --- pallets/exodus/Cargo.toml | 2 +- pallets/exodus/src/types/exodus_request.rs | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/pallets/exodus/Cargo.toml b/pallets/exodus/Cargo.toml index 101c19f..155921b 100644 --- a/pallets/exodus/Cargo.toml +++ b/pallets/exodus/Cargo.toml @@ -1,6 +1,6 @@ [package] name = "ghost-exodus" -version = "0.0.19" +version = "0.0.20" description = "Threshold signature generation with DKG included" license.workspace = true authors.workspace = true diff --git a/pallets/exodus/src/types/exodus_request.rs b/pallets/exodus/src/types/exodus_request.rs index 17084a1..1e624e1 100644 --- a/pallets/exodus/src/types/exodus_request.rs +++ b/pallets/exodus/src/types/exodus_request.rs @@ -387,7 +387,7 @@ where sp_runtime::Rounding::Down )?; - let bounty_uint32 = scaled_bounty as u32; + let bounty_uint32 = scaled_bounty.min(u32::MAX as u128) as u32; buffer[28..32].copy_from_slice(&bounty_uint32.to_be_bytes()); let mut amount_buffer = [0u8; 32];