We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent f5664f5 commit 31cc4ccCopy full SHA for 31cc4cc
compiler-rt/lib/fuzzer/FuzzerUtilFuchsia.cpp
@@ -607,7 +607,13 @@ size_t PageSize() {
607
}
608
609
void SetThreadName(std::thread &thread, const std::string &name) {
610
- // TODO ?
+ if (name.size() > 31)
611
+ name.resize(31);
612
+ zx_status_t s;
613
+ if ((s = zx_object_set_property(thread.native_handle(), ZX_PROP_NAME,
614
+ name.c_str(), name.size())) != ZX_OK)
615
+ Printf("SetThreadName for name %s failed: %s", name.c_str(),
616
+ zx_status_get_string(s));
617
618
619
} // namespace fuzzer
0 commit comments