Skip to content

Commit 7c34d9c

Browse files
committed
Haiku: Use common thread set_name stub
1 parent 7e91b86 commit 7c34d9c

File tree

1 file changed

+5
-7
lines changed

1 file changed

+5
-7
lines changed

src/libstd/sys/unix/thread.rs

+5-7
Original file line numberDiff line numberDiff line change
@@ -115,14 +115,12 @@ impl Thread {
115115
name.as_ptr() as *mut libc::c_void);
116116
}
117117
}
118-
#[cfg(any(target_env = "newlib", target_os = "solaris", target_os = "emscripten"))]
118+
#[cfg(any(target_env = "newlib",
119+
target_os = "solaris",
120+
target_os = "haiku",
121+
target_os = "emscripten"))]
119122
pub fn set_name(_name: &CStr) {
120-
// Newlib, Illumos and Emscripten have no way to set a thread name.
121-
}
122-
123-
#[cfg(target_os = "haiku")]
124-
pub fn set_name(_name: &CStr) {
125-
// Haiku has no way to set a thread name.
123+
// Newlib, Illumos, Haiku, and Emscripten have no way to set a thread name.
126124
}
127125

128126
pub fn sleep(dur: Duration) {

0 commit comments

Comments
 (0)