From cbc4591f68a56db1ab9632b5541a87c23d005072 Mon Sep 17 00:00:00 2001 From: Brad Smith Date: Fri, 4 Sep 2026 03:12:32 -0400 Subject: [PATCH] OpenBSD: add getexecpath() --- libc-test/semver/openbsd.txt | 1 + src/unix/bsd/netbsdlike/openbsd/mod.rs | 1 + 2 files changed, 2 insertions(+) diff --git a/libc-test/semver/openbsd.txt b/libc-test/semver/openbsd.txt index a5116d75c4b8..32eae12f225b 100644 --- a/libc-test/semver/openbsd.txt +++ b/libc-test/semver/openbsd.txt @@ -1187,6 +1187,7 @@ futimes getdomainname getdtablesize getentropy +getexecpath getfsstat getgrent getgrgid diff --git a/src/unix/bsd/netbsdlike/openbsd/mod.rs b/src/unix/bsd/netbsdlike/openbsd/mod.rs index 4fddbb5988e4..bdd05afdab2d 100644 --- a/src/unix/bsd/netbsdlike/openbsd/mod.rs +++ b/src/unix/bsd/netbsdlike/openbsd/mod.rs @@ -2056,6 +2056,7 @@ extern "C" { pub fn getfsstat(buf: *mut statfs, bufsize: size_t, flags: c_int) -> c_int; pub fn elf_aux_info(aux: c_int, buf: *mut c_void, buflen: c_int) -> c_int; + pub fn getexecpath(buf: *mut c_char, bufsize: size_t) -> c_int; } #[link(name = "execinfo")]