diff --git a/src/uu/sync/src/sync.rs b/src/uu/sync/src/sync.rs index 38d5f1044..abcdf4099 100644 --- a/src/uu/sync/src/sync.rs +++ b/src/uu/sync/src/sync.rs @@ -40,10 +40,10 @@ mod platform { /// # Safety /// This function is unsafe because it calls `libc::sync` or `libc::syscall` which are unsafe. pub unsafe fn do_sync() -> UResult<()> { - // see https://github.com/rust-lang/libc/pull/2161 - #[cfg(target_os = "android")] - libc::syscall(libc::SYS_sync); unsafe { + // see https://github.com/rust-lang/libc/pull/2161 + #[cfg(target_os = "android")] + libc::syscall(libc::SYS_sync); #[cfg(not(target_os = "android"))] libc::sync(); }