X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/3d5930b5ea5cd28d97ca9df147cd48bc51061480..1406dc01b2d886bda2f64294e86d3c59d6a80dcd:/include/wx/thread.h diff --git a/include/wx/thread.h b/include/wx/thread.h index 9e07b4e821..999d4f9166 100644 --- a/include/wx/thread.h +++ b/include/wx/thread.h @@ -506,7 +506,7 @@ public: // does it! // // will fill the rc pointer with the thread exit code if it's !NULL - wxThreadError Delete(ExitCode *rc = (ExitCode *)NULL); + wxThreadError Delete(ExitCode *rc = NULL); // waits for a joinable thread to finish and returns its exit code // @@ -633,11 +633,10 @@ class WXDLLIMPEXP_BASE wxThreadHelper private: void KillThread() { - // If detached thread is about to finish, it will set - // m_thread to NULL so don't delete it then - // But if KillThread is called before detached thread - // sets it to NULL, then the thread object still - // exists and can be killed + // If wxThreadHelperThread is detached and is about to finish, it will + // set m_thread to NULL so don't delete it then. + // But if KillThread is called before wxThreadHelperThread (in detached mode) + // sets it to NULL, then the thread object still exists and can be killed wxCriticalSectionLocker locker(m_critSection); if ( m_thread )