create_thread : sometime thread name is null

This commit is contained in:
georgemoralis 2024-05-02 17:14:30 +03:00
parent 90e3e47c4d
commit d2cc256b28
1 changed files with 5 additions and 1 deletions

View File

@ -827,7 +827,11 @@ int PS4_SYSV_ABI scePthreadCreate(ScePthread* thread, const ScePthreadAttr* attr
int result = pthread_copy_attributes(&(*thread)->attr, attr);
if (result == 0) {
(*thread)->name = name;
if (name != NULL) {
(*thread)->name = name;
} else {
(*thread)->name = "no-name";
}
(*thread)->entry = start_routine;
(*thread)->arg = arg;
(*thread)->is_almost_done = false;