Skip to content

Commit

Permalink
Fix patch for i8 err on arm64
Browse files Browse the repository at this point in the history
  • Loading branch information
ayufan committed Dec 12, 2024
1 parent fc1bef7 commit 1b5a42b
Showing 1 changed file with 14 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ commit 585e751ad6cbf1d2fe212cca0004534ec9c8b472
Author: Kamil Trzciński <ayufan@ayufan.eu>
Date: Thu Dec 12 20:29:27 2024 +0100

Fix mismatched types on arm64 for `src/crypt.rs`
Fix mismatched types on arm64 for `src/crypt.rs` and `src/fs/dir.rs`

--> /src/proxmox/proxmox-sys/src/crypt.rs:74:67
|
Expand Down Expand Up @@ -33,4 +33,17 @@ index 3313f668..a11c19f1 100644
+ if output.first().is_none() || Some(&('*' as libc::c_char)) == output.first() {
bail!("internal error: crypt_gensalt_rn could not create a valid salt");
}
diff --git a/proxmox-sys/src/fs/dir.rs b/proxmox-sys/src/fs/dir.rs
index e4f45bbd..a982866c 100644
--- a/proxmox-sys/src/fs/dir.rs
+++ b/proxmox-sys/src/fs/dir.rs
@@ -213,7 +213,7 @@ pub fn make_tmp_dir<P: AsRef<Path>>(
// 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();

0 comments on commit 1b5a42b

Please # to comment.