History

add check to prevent self-join when deleting XThread in bg

chadawagner committed 8 years ago

Commit 5c50c9d1 parent ed8dbc61 file · +1 −1Browse files

Showing the changes to src/core/util_thread.cpp (1 of 1 file). Show all

Unified · Split

src/core/util_thread.cpp+1−1
@@ -67,7 +67,7 @@ XThread::XThread( ) · 66 unmodified lines
6767 //-----------------------------------------------------------------------------
6868 XThread::~XThread( )
6969 {
70− if( thread != 0 )
70+ if( thread != 0 && thread != pthread_self() )
7171 {
7272 #if defined(__PLATFORM_MACOSX__) || defined(__PLATFORM_LINUX__) || defined(__WINDOWS_PTHREAD__)
7373 pthread_cancel(thread);

Keyboard shortcuts

General

Show keyboard shortcuts
?
Focus the current search
/

Issues and pull requests

Open filters
f

Issues, pull requests and Inbox

Select next item
j↓
Select previous item
k↑
Open selected item
Enter
Dismiss filters or clear selection
Esc

Repository code

Go to file
t