[Opalvoip-svn] SF.net SVN: opalvoip:[34794] ptlib/branches/v2_16
Brought to you by:
csoutheren,
rjongbloed
From: <rjo...@us...> - 2016-04-25 13:19:13
|
Revision: 34794 http://sourceforge.net/p/opalvoip/code/34794 Author: rjongbloed Date: 2016-04-25 13:19:10 +0000 (Mon, 25 Apr 2016) Log Message: ----------- Merged revision(s) 34792-34793 from ptlib/trunk: Fixed tiny race condition where PThread::IsTerminated() could return true when thread is starting up. Modified Paths: -------------- ptlib/branches/v2_16/src/ptlib/unix/tlibthrd.cxx Property Changed: ---------------- ptlib/branches/v2_16/ Index: ptlib/branches/v2_16 =================================================================== --- ptlib/branches/v2_16 2016-04-25 13:15:43 UTC (rev 34793) +++ ptlib/branches/v2_16 2016-04-25 13:19:10 UTC (rev 34794) Property changes on: ptlib/branches/v2_16 ___________________________________________________________________ Modified: svn:mergeinfo ## -10,4 +10,4 ## /ptlib/branches/v2_4:21086,21094,21147,21160,21185,21281,21296,21305,21322,21337,21363,21467,21471-21472,21506,21508,21623,21695,21744,21746,21763,22241,22958,23045-23046,23061,23066,23712 /ptlib/branches/v2_6:22195,22243,22295,22304,22311,22317,22320,22356,22458,22509,22587,22601-22602,22611,22629,22633,22673,22681,22729,22731-22732,22736,22742,22848,22960,22992,23161,23163,23167,23169,23177,23239,23291,23298,23336,23429,23595,23823,23827,23873,24816 /ptlib/branches/v2_8:24034,24044,24046,24054,24060,24065,24084,24090,24113,24136,24142,24165-24166,24168,24172,24367,24372,24410,24540,24992 -/ptlib/trunk:34109-34115,34121,34140,34142-34143,34146-34149,34152-34154,34169,34171-34172,34180,34182,34184,34194,34219,34221,34231-34232,34244-34245,34254,34267-34268,34280-34284,34298-34315,34335,34344-34345,34347,34354-34356,34366,34379,34398,34405-34411,34418-34423,34493-34508,34581,34584,34722,34740-34745,34774 +/ptlib/trunk:34109-34115,34121,34140,34142-34143,34146-34149,34152-34154,34169,34171-34172,34180,34182,34184,34194,34219,34221,34231-34232,34244-34245,34254,34267-34268,34280-34284,34298-34315,34335,34344-34345,34347,34354-34356,34366,34379,34398,34405-34411,34418-34423,34493-34508,34581,34584,34722,34740-34745,34774,34792-34793 \ No newline at end of property Modified: ptlib/branches/v2_16/src/ptlib/unix/tlibthrd.cxx =================================================================== --- ptlib/branches/v2_16/src/ptlib/unix/tlibthrd.cxx 2016-04-25 13:15:43 UTC (rev 34793) +++ ptlib/branches/v2_16/src/ptlib/unix/tlibthrd.cxx 2016-04-25 13:19:10 UTC (rev 34794) @@ -791,8 +791,15 @@ if (m_type == e_IsProcess) return false; // Process is always still running - if (PX_state == PX_finished) - return true; + switch (PX_state) { + case PX_starting : + case PX_firstResume : + return false; + case PX_finished: + return true; + default : + break; + } // See if thread is still running, copy variable in case changes between two statements pthread_t id = m_threadId; This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |