We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
bash-prg-hash
1 parent 98e5ed5 commit 6e282c5Copy full SHA for 6e282c5
1 file changed
bash-prg-hash/src/lib.rs
@@ -90,7 +90,7 @@ impl<const RATE: usize, const CAPACITY: usize> TryCustomizedInit for BashPrgHash
90
// Step 5: S[pos...1472) <- 0^{1472-pos}
91
92
let mut buf = [0u8; 8 * STATE_WORDS];
93
- buf[0] = u8::try_from(header_len / 4).expect("header_len fits into u8");
+ buf[0] = u8::try_from(header_len * 4).expect("header_len fits into u8");
94
buf[1..][..header_len].copy_from_slice(header);
95
96
let mut state = [0u64; STATE_WORDS];
0 commit comments