diff --git a/src/linux/mod.rs b/src/linux/mod.rs index ef57868..97c648b 100644 --- a/src/linux/mod.rs +++ b/src/linux/mod.rs @@ -134,9 +134,11 @@ impl Sandbox for LinuxSandbox { } // Use landlock only if namespaces failed. - if namespace_result.is_ok() { - return Ok(()); - } + namespace_result.unwrap(); + println!("NAMESPACE OK"); + // if namespace_result.is_ok() { + // return Ok(()); + // } // Apply landlock rules. let status = self.landlock.restrict_self()?; diff --git a/tests/fs_without_landlock.rs b/tests/fs_without_landlock.rs index 391b81c..e981838 100644 --- a/tests/fs_without_landlock.rs +++ b/tests/fs_without_landlock.rs @@ -52,6 +52,7 @@ fn main() { // Access to the private file is prohibited. let result = fs::read_to_string(private_path); assert!(result.is_err()); + panic!(); } #[cfg(not(target_os = "linux"))]