mirror of
https://github.com/panda3d/panda3d.git
synced 2025-09-26 14:43:50 -04:00
pipeline: Display error if joining thread failed
This can occur if a thread tries to call join on itself
This commit is contained in:
parent
d6055cc927
commit
863a38e901
@ -169,7 +169,12 @@ join() {
|
||||
if (!_detached) {
|
||||
_mutex.unlock();
|
||||
void *return_val;
|
||||
pthread_join(_thread, &return_val);
|
||||
int result = pthread_join(_thread, &return_val);
|
||||
if (result != 0) {
|
||||
thread_cat.error()
|
||||
<< "Failed to join thread " << _parent_obj->get_name()
|
||||
<< ": " << strerror(result) << "\n";
|
||||
}
|
||||
_detached = true;
|
||||
return;
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user