feat: made unix-loader more stable on FreeBSD

This commit is contained in:
Andrew Rioux
2025-02-03 02:37:17 -05:00
parent d8a277e769
commit 00331ec550
9 changed files with 159 additions and 59 deletions

View File

@@ -1,3 +1,14 @@
fn main() {
println!("Hello, world!");
#[cfg(target_os = "freebsd")]
unsafe {
let sem = libc::sem_open(c"/libcrypto".as_ptr(), 0);
libc::sem_post(sem);
}
println!("Hello, world!");
unsafe { println!("\n{}\n", libc::getpid()) };
loop {}
}