You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
fork example might be violating its own safety rules #2782
Ok(ForkResult::Child) => {// Unsafe to use `println!` (or `unwrap`) here. See Safety.write(std::io::stdout(),"I'm a new child process\n".as_bytes()).ok();unsafe{ libc::_exit(0)};}
To be safe, this block should use only async-signal-safe functions, however, I'm not sure if writing to std::io::stdout() is async-signal-safe. The write syscall itself is signal safe, but Rust muddies the waters, because std::io::stdout is wrapped in a reentrant lock, which may or may not cause issues.
Activity