From 44966326c1314dd0e8e3ddbe5f50ec568fb02db0 Mon Sep 17 00:00:00 2001 From: Deirdre Connolly Date: Sat, 20 Mar 2021 12:58:54 -0400 Subject: [PATCH] Orchard: turns out you can't store 10 bits in a u8 --- zebra-chain/src/orchard/sinsemilla.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/zebra-chain/src/orchard/sinsemilla.rs b/zebra-chain/src/orchard/sinsemilla.rs index ee5f27fa1..1528a14b8 100644 --- a/zebra-chain/src/orchard/sinsemilla.rs +++ b/zebra-chain/src/orchard/sinsemilla.rs @@ -82,7 +82,7 @@ pub fn sinsemilla_hash_to_point(D: &[u8], M: &BitVec) -> pallas::Point // https://zips.z.cash/protocol/protocol.pdf#concretesinsemillahash for chunk in M.chunks(k) { // Pad each chunk with zeros. - let mut store = 0u8; + let mut store = 0u16; let bits = store.bits_mut::(); chunk .iter()