Fix try_into in PyAny::cast_as in libafl_qemu
This commit is contained in:
parent
3d436b7519
commit
e46bb8643a
@ -151,7 +151,7 @@ pub fn python_module(py: Python, m: &PyModule) -> PyResult<()> {
|
|||||||
if any.is_none() {
|
if any.is_none() {
|
||||||
SyscallHookResult::new(None)
|
SyscallHookResult::new(None)
|
||||||
} else {
|
} else {
|
||||||
let a: Result<&PyInt, _> = any.try_into();
|
let a: Result<&PyInt, _> = any.cast_as();
|
||||||
if let Ok(i) = a {
|
if let Ok(i) = a {
|
||||||
SyscallHookResult::new(Some(
|
SyscallHookResult::new(Some(
|
||||||
i.extract().expect("Invalid syscall hook return value"),
|
i.extract().expect("Invalid syscall hook return value"),
|
||||||
|
Loading…
x
Reference in New Issue
Block a user