From a3ccbe02d0ffbab335853641bda38147a383b4a5 Mon Sep 17 00:00:00 2001 From: Jack May Date: Tue, 15 Oct 2019 22:40:31 -0700 Subject: [PATCH] Create genesis with the requested amount (#6384) --- programs/librapay_api/src/lib.rs | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/programs/librapay_api/src/lib.rs b/programs/librapay_api/src/lib.rs index 3821d99b3..206c19acb 100644 --- a/programs/librapay_api/src/lib.rs +++ b/programs/librapay_api/src/lib.rs @@ -32,9 +32,8 @@ pub fn create_genesis(from_key: &Keypair, client: &T, amount: u64) -> &from_key.pubkey(), &libra_genesis_key.pubkey(), 1, - bincode::serialize(&LibraAccountState::create_genesis(1)) - .unwrap() - .len() as u64, + bincode::serialized_size(&LibraAccountState::create_genesis(amount).unwrap()).unwrap() + as u64, &solana_move_loader_api::id(), ); client.send_instruction(&from_key, instruction).unwrap();