From 50426862403519bff72af8a2847d1c1f77829f2d Mon Sep 17 00:00:00 2001 From: Chris Heaney Date: Thu, 5 Jun 2025 18:13:40 -0400 Subject: [PATCH] program: try to fix binary search for max order size --- programs/drift/src/math/orders.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/programs/drift/src/math/orders.rs b/programs/drift/src/math/orders.rs index 9b0a9c1dc5..3ec1908900 100644 --- a/programs/drift/src/math/orders.rs +++ b/programs/drift/src/math/orders.rs @@ -965,7 +965,7 @@ pub fn calculate_max_perp_order_size( let mut order_size = 0_u64; let mut updated_margin_ratio = margin_ratio; - for _ in 0..6 { + for _ in 0..7 { let (new_order_size, new_margin_ratio) = calculate_order_size_and_margin_ratio(updated_margin_ratio)?; order_size = new_order_size;