Handle v1 Monero TXs spending v2 outputs

Also tightens read/fixes a few potential panics.
This commit is contained in:
Luke Parker
2023-08-21 11:41:14 -04:00
parent f2872a2e07
commit bfb5401336
2 changed files with 35 additions and 10 deletions

View File

@@ -52,7 +52,7 @@ mod binaries {
let blob = hex::decode(res.blob).expect("node returned non-hex block");
let block = Block::read(&mut blob.as_slice())
.unwrap_or_else(|_| panic!("couldn't deserialize block {block_i}"));
.unwrap_or_else(|e| panic!("couldn't deserialize block {block_i}: {e}"));
assert_eq!(block.hash(), hash, "hash differs");
assert_eq!(block.serialize(), blob, "serialization differs");