Skip to content

Commit 462aa6d

Browse files
committed
fix(ffi): replace todo!() panic with Err in ResponseValue::from_value
The catch-all arm for unsupported value types (Push, BigInt, Attribute) previously used todo!() which panics. Panicking across an FFI boundary is undefined behavior. Return an error string instead. Signed-off-by: currantw <taylor.curran@improving.com>
1 parent 1aa8af6 commit 462aa6d

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

rust/src/ffi.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -734,7 +734,7 @@ impl ResponseValue {
734734
size,
735735
})
736736
}
737-
_ => todo!(), // push, bigint, attribute
737+
_ => Err("Unsupported Redis value type in FFI response serialization".into()),
738738
}
739739
}
740740

0 commit comments

Comments
 (0)