Skip to content

Commit 014e3b6

Browse files
authored
Merge pull request #74 from KeystoneHQ/fix-cbor
fix: cbor decode empty array
2 parents 1ceedf2 + 1d3826d commit 014e3b6

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

libs/ur-registry/src/cbor.rs

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -37,6 +37,9 @@ where
3737
F: FnMut(u64, &mut T, &mut Decoder<'b>) -> Result<(), minicbor::decode::Error>,
3838
{
3939
let entries = d.array()?;
40+
if let Some(0) = entries {
41+
return Ok(());
42+
}
4043
let mut index = 0;
4144
loop {
4245
(cb)(index, obj, d)?;

0 commit comments

Comments
 (0)