Skip to content

Commit 4c9329a

Browse files
committed
Updated marshal to correct from_hex_12k implementation
1 parent 8533316 commit 4c9329a

File tree

3 files changed

+2
-2
lines changed

3 files changed

+2
-2
lines changed

docs/emu6502_web_bg.wasm

740 Bytes
Binary file not shown.
740 Bytes
Binary file not shown.

emulator/src/marshal.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -208,11 +208,11 @@ pub fn from_hex_12k<'de, D: Deserializer<'de>>(deserializer: D) -> Result<Vec<u8
208208
let result = from_hex(deserializer);
209209
if let Ok(ref value) = result
210210
&& value.len() != 0x3000
211-
&& value.len() % 0x20000 != 0
211+
&& value.len() % (0x3000 * 8) != 0
212212
{
213213
return Err(Error::invalid_value(
214214
Unexpected::Seq,
215-
&"Array should be 12K or multiple of 128k",
215+
&"Array should be 12K or multiple of 96k",
216216
));
217217
}
218218
result

0 commit comments

Comments
 (0)