diff options
| author | Oli Scherer <github35764891676564198441@oli-obk.de> | 2025-02-26 06:33:17 +0000 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2025-02-26 06:33:17 +0000 |
| commit | 88a8309a4ba67a20fca7ef1c6a66739e0defb2ed (patch) | |
| tree | 141286e4ff4419e4610c80f4e1800a3d2310b3be | |
| parent | 366912323b46c52bbeae8aedb72bf807585a4d87 (diff) | |
| parent | 6de7fd1feec480ba6af5eaa3a412255a8c8dd3d9 (diff) | |
| download | rust-88a8309a4ba67a20fca7ef1c6a66739e0defb2ed.tar.gz rust-88a8309a4ba67a20fca7ef1c6a66739e0defb2ed.zip | |
Merge pull request #4210 from tiif/small-fix-2
Resolve more FIXMEs
| -rw-r--r-- | src/tools/miri/tests/pass-dep/libc/libc-pipe.rs | 8 |
1 files changed, 2 insertions, 6 deletions
diff --git a/src/tools/miri/tests/pass-dep/libc/libc-pipe.rs b/src/tools/miri/tests/pass-dep/libc/libc-pipe.rs index 01433edf9a3..d6072c2569e 100644 --- a/src/tools/miri/tests/pass-dep/libc/libc-pipe.rs +++ b/src/tools/miri/tests/pass-dep/libc/libc-pipe.rs @@ -56,8 +56,7 @@ fn test_pipe_threaded() { assert_eq!(res, 5); assert_eq!(buf, "abcde".as_bytes()); }); - // FIXME: we should yield here once blocking is implemented. - //thread::yield_now(); + thread::yield_now(); let data = "abcde".as_bytes().as_ptr(); let res = unsafe { libc::write(fds[1], data as *const libc::c_void, 5) }; assert_eq!(res, 5); @@ -65,14 +64,11 @@ fn test_pipe_threaded() { // Read and write from different direction let thread2 = thread::spawn(move || { - // FIXME: we should yield here once blocking is implemented. - //thread::yield_now(); + thread::yield_now(); let data = "12345".as_bytes().as_ptr(); let res = unsafe { libc::write(fds[1], data as *const libc::c_void, 5) }; assert_eq!(res, 5); }); - // FIXME: we should not yield here once blocking is implemented. - thread::yield_now(); let mut buf: [u8; 5] = [0; 5]; let res = unsafe { libc::read(fds[0], buf.as_mut_ptr().cast(), buf.len() as libc::size_t) }; assert_eq!(res, 5); |
