diff options
| author | Eric Huss <eric@huss.org> | 2025-02-12 14:14:12 -0800 |
|---|---|---|
| committer | Eric Huss <eric@huss.org> | 2025-02-13 13:10:27 -0800 |
| commit | 1b3940f07fd93fdc779ac958abe7e72bb5b26254 (patch) | |
| tree | 3338cabf089340c9794bdea9628edc28e81fe9be /library | |
| parent | 1ba59f868a937a4ce39b28c5d496f06cf8e977d7 (diff) | |
| download | rust-1b3940f07fd93fdc779ac958abe7e72bb5b26254.tar.gz rust-1b3940f07fd93fdc779ac958abe7e72bb5b26254.zip | |
std: Apply fixes for tail drop expressions
Diffstat (limited to 'library')
| -rw-r--r-- | library/std/src/sys/pal/unix/linux/pidfd/tests.rs | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/library/std/src/sys/pal/unix/linux/pidfd/tests.rs b/library/std/src/sys/pal/unix/linux/pidfd/tests.rs index fb928c76fbd..17b06bea912 100644 --- a/library/std/src/sys/pal/unix/linux/pidfd/tests.rs +++ b/library/std/src/sys/pal/unix/linux/pidfd/tests.rs @@ -45,8 +45,8 @@ fn test_command_pidfd() { .expect_err("pidfd should not have been created"); // exercise the fork/exec path since the earlier attempts may have used pidfd_spawnp() - let mut child = - unsafe { Command::new("false").pre_exec(|| Ok(())) }.create_pidfd(true).spawn().unwrap(); + let mut cmd = Command::new("false"); + let mut child = unsafe { cmd.pre_exec(|| Ok(())) }.create_pidfd(true).spawn().unwrap(); assert!(child.id() > 0 && child.id() < -1i32 as u32); |
