Lines Matching full:safety

37         // SAFETY: This expression creates a temporary value that is dropped at the end of the
43 // `begin_new_exec()` is responsible for safety.
98 // SAFETY: By design, the only way to access a `Task` is via the `current` function or via an
104 // SAFETY: It's OK to access `Task` through shared references from other threads because we're
162 // SAFETY: Getting the current pointer is always safe.
171 /// # Safety
186 // SAFETY: The returned reference borrows from this `TaskRef`, so it cannot outlive
208 // SAFETY: The pid of a task never changes after initialization, so reading this field is
215 // SAFETY: The tgid of a task never changes after initialization, so reading this field is
223 // SAFETY: It's always safe to call `task_uid` on a valid task.
230 // SAFETY: It's always safe to call `signal_pending` on a valid task.
237 // SAFETY: By the type invariant, we know that `self.0` is valid.
242 // SAFETY: `ptr` is valid by the safety requirements of this function. And we own a
257 // SAFETY: By the type invariant, we know that `self.0` is valid. We received a valid
267 // SAFETY: It's always safe to call `wake_up_process` on a valid task, even if the task
279 // SAFETY: The `mm` field of `current` is not modified from other threads, so reading it is
287 // SAFETY: If `current->mm` is non-null, then it references a valid mm with a non-zero
312 // SAFETY: It is safe to call `task_active_pid_ns` without RCU protection when calling it
329 // SAFETY: If `current`'s pid ns is non-null, then it references a valid pid ns.
338 // SAFETY: The group leader of a task never changes while the task is running, and `self`
342 // SAFETY: `current->group_leader` stays valid for at least the duration in which `current`
349 // SAFETY: The type invariants guarantee that `Task` is always refcounted.
353 // SAFETY: The existence of a shared reference means that the refcount is nonzero.
359 // SAFETY: The safety requirements guarantee that the refcount is nonzero.
377 // SAFETY: Just an FFI call.
398 // SAFETY: Just an FFI call.
406 // SAFETY: Just an FFI call.
429 // SAFETY: `file.as_ptr()` is valid for reading and guaranteed to be nul-terminated.
433 // SAFETY: Always safe to call.