From dbaa2df500dd89fea57880437d91ef763c32d6e9 Mon Sep 17 00:00:00 2001 From: Sergey Konev Date: Thu, 7 Nov 2024 02:15:55 +0300 Subject: [PATCH] Small fix for cross-platforming of low-level C bindings --- proxmox-sys/src/fs/dir.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/proxmox-sys/src/fs/dir.rs b/proxmox-sys/src/fs/dir.rs index c903ab87..4db63409 100644 --- a/proxmox-sys/src/fs/dir.rs +++ b/proxmox-sys/src/fs/dir.rs @@ -208,7 +208,7 @@ pub fn make_tmp_dir>( // Push NULL byte so that we have a proper NULL-terminated string template.push(0); - let returned_buffer = unsafe { libc::mkdtemp(template.as_mut_ptr() as *mut i8) }; + let returned_buffer = unsafe { libc::mkdtemp(template.as_mut_ptr() as *mut libc::c_char) }; // Check errno immediately, so that nothing else can overwrite it. let err = std::io::Error::last_os_error();