mirror of
https://github.com/nyanmisaka/mpp.git
synced 2025-12-26 11:17:44 +01:00
fix[mpp_thread]: Fix thread name is not set
https://github.com/rockchip-linux/mpp/pull/887 Change-Id: I96937a2fb42cb40f60d432ead3c826b6d89bee23 Signed-off-by: Herman Chen <herman.chen@rock-chips.com>
This commit is contained in:
parent
32767f39fb
commit
9751e7ac96
1 changed files with 0 additions and 2 deletions
|
|
@ -63,12 +63,10 @@ void mpp_thread_start(MppThread *thread)
|
|||
if (mpp_thread_get_status(thread, THREAD_WORK) == MPP_THREAD_UNINITED) {
|
||||
mpp_thread_set_status(thread, MPP_THREAD_RUNNING, THREAD_WORK);
|
||||
if (0 == pthread_create(&thread->thd, &attr, thread->func, thread->ctx)) {
|
||||
#ifndef __linux__
|
||||
int ret = pthread_setname_np(thread->thd, thread->name);
|
||||
if (ret) {
|
||||
mpp_err("thread %p setname %s failed\n", thread->func, thread->name);
|
||||
}
|
||||
#endif
|
||||
thread_dbg(THREAD_DBG_FUNC, "thread %s %p context %p create success\n",
|
||||
thread->name, thread->func, thread->ctx);
|
||||
} else {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue