create_thread : sometime thread name is null
This commit is contained in:
parent
90e3e47c4d
commit
d2cc256b28
|
@ -827,7 +827,11 @@ int PS4_SYSV_ABI scePthreadCreate(ScePthread* thread, const ScePthreadAttr* attr
|
||||||
int result = pthread_copy_attributes(&(*thread)->attr, attr);
|
int result = pthread_copy_attributes(&(*thread)->attr, attr);
|
||||||
|
|
||||||
if (result == 0) {
|
if (result == 0) {
|
||||||
|
if (name != NULL) {
|
||||||
(*thread)->name = name;
|
(*thread)->name = name;
|
||||||
|
} else {
|
||||||
|
(*thread)->name = "no-name";
|
||||||
|
}
|
||||||
(*thread)->entry = start_routine;
|
(*thread)->entry = start_routine;
|
||||||
(*thread)->arg = arg;
|
(*thread)->arg = arg;
|
||||||
(*thread)->is_almost_done = false;
|
(*thread)->is_almost_done = false;
|
||||||
|
|
Loading…
Reference in New Issue