about summary refs log tree commit diff
path: root/library/std/src/sys/unix/fs.rs
diff options
context:
space:
mode:
authorbors <bors@rust-lang.org>2023-12-14 11:14:03 +0000
committerbors <bors@rust-lang.org>2023-12-14 11:14:03 +0000
commit1aa6aefdc92555b3fbc5ae4c99365df9845a3e31 (patch)
tree6f484d11a31b271f1e06739754ba4159521da813 /library/std/src/sys/unix/fs.rs
parent9d49eb76c47a139ef71da4ab56aa9aeca5f24913 (diff)
parentc0134887d2b4cbac421babcd40710cc9b755f931 (diff)
downloadrust-1aa6aefdc92555b3fbc5ae4c99365df9845a3e31.tar.gz
rust-1aa6aefdc92555b3fbc5ae4c99365df9845a3e31.zip
Auto merge of #118566 - klensy:cstr-new, r=WaffleLapkin
use c literals in compiler and library

Relands refreshed https://github.com/rust-lang/rust/pull/111647
Diffstat (limited to 'library/std/src/sys/unix/fs.rs')
-rw-r--r--library/std/src/sys/unix/fs.rs2
1 files changed, 1 insertions, 1 deletions
diff --git a/library/std/src/sys/unix/fs.rs b/library/std/src/sys/unix/fs.rs
index e3455cfef33..72e7b1b1fc3 100644
--- a/library/std/src/sys/unix/fs.rs
+++ b/library/std/src/sys/unix/fs.rs
@@ -1140,7 +1140,7 @@ impl File {
         cfg_has_statx! {
             if let Some(ret) = unsafe { try_statx(
                 fd,
-                b"\0" as *const _ as *const c_char,
+                c"".as_ptr() as *const c_char,
                 libc::AT_EMPTY_PATH | libc::AT_STATX_SYNC_AS_STAT,
                 libc::STATX_ALL,
             ) } {