Skip to content

Commit a128dcf

Browse files
committed
Auto merge of #2422 - devnexen:obsd_nbsd_getnamenp, r=JohnTitor
netbsd/openbsd add get thread name api.
2 parents 0ae17dc + 8971f45 commit a128dcf

File tree

4 files changed

+4
-0
lines changed

4 files changed

+4
-0
lines changed

libc-test/semver/netbsd.txt

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1287,6 +1287,7 @@ pthread_cancel
12871287
pthread_condattr_setclock
12881288
pthread_getattr_np
12891289
pthread_getaffinity_np
1290+
pthread_getname_np
12901291
pthread_kill
12911292
pthread_mutex_timedlock
12921293
pthread_spin_destroy

libc-test/semver/openbsd.txt

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1031,6 +1031,7 @@ pthread_attr_getguardsize
10311031
pthread_attr_getstack
10321032
pthread_cancel
10331033
pthread_condattr_setclock
1034+
pthread_get_name_np
10341035
pthread_kill
10351036
pthread_main_np
10361037
pthread_mutex_timedlock

src/unix/bsd/netbsdlike/netbsd/mod.rs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2154,6 +2154,7 @@ extern "C" {
21542154
pub fn mq_unlink(name: *const ::c_char) -> ::c_int;
21552155
pub fn ptrace(request: ::c_int, pid: ::pid_t, addr: *mut ::c_void, data: ::c_int) -> ::c_int;
21562156
pub fn utrace(label: *const ::c_char, addr: *mut ::c_void, len: ::size_t) -> ::c_int;
2157+
pub fn pthread_getname_np(t: ::pthread_t, name: *mut ::c_char, len: ::size_t) -> ::c_int;
21572158
pub fn pthread_setname_np(
21582159
t: ::pthread_t,
21592160
name: *const ::c_char,

src/unix/bsd/netbsdlike/openbsd/mod.rs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1546,6 +1546,7 @@ extern "C" {
15461546
stacksize: *mut ::size_t,
15471547
) -> ::c_int;
15481548
pub fn pthread_main_np() -> ::c_int;
1549+
pub fn pthread_get_name_np(tid: ::pthread_t, name: *mut ::c_char, len: ::size_t);
15491550
pub fn pthread_set_name_np(tid: ::pthread_t, name: *const ::c_char);
15501551
pub fn pthread_stackseg_np(thread: ::pthread_t, sinfo: *mut ::stack_t) -> ::c_int;
15511552

0 commit comments

Comments
 (0)