diff --git a/kernel/src/objects/untyped.rs b/kernel/src/objects/untyped.rs index fecca9b..89d7ef0 100644 --- a/kernel/src/objects/untyped.rs +++ b/kernel/src/objects/untyped.rs @@ -89,7 +89,7 @@ impl UntypedCap<'_> { slots .iter() .any(|cte| NullCap::try_from(cte).is_err()) - .then_ok((), SysError::CapTypeMismatch)?; + .else_ok((), SysError::CapTypeMismatch)?; // Start allocating from free_offset // Notice: in vallina seL4, it will check whether there are child nodes,