Status: Unconfirmed Owner: ---- Labels: OS-Mac Area-Misc Pri-2 Type-Bug New issue 23245 by ramosian.glider: A Debug-mode data race in base::Thread http://code.google.com/p/chromium/issues/detail?id=23245
Chrome Version : 27359 URLs (if applicable) : OS version : Darwin Kernel Version 9.7.0: Tue Mar 31 22:52:17 PDT 2009; root:xnu-1228.12.14~1/RELEASE_I386 i386 base/thread.cc contains a potential data race discoverable by ThreadSanitizer (see http://build.chromium.org/buildbot/waterfall.fyi/builders/Modules%20Mac%20(tsan)/builds/166/steps/valgrind%20test%3A%20base/logs/stdio). Thread::StopSoon (base/thread.cc:122) and Thread::ThreadMain(base/thread.cc:163) access thread_id_ concurrently, so if Thread::StopSoon is called twice the second call may proceed after the thread actually stops and Thread::thread_id_ is set to 0. On Mac OS PlatformThread::CurrentId() is not guaranteed to return a non-zero value (it is based on mach_thread_self(), which may return MACH_PORT_NULL if there are any resource failures or other errors), therefore in this case the second call to Thread::StopSoon may crash on the DCHECK_NE at base/thread.cc:122. This data race is a Debug-mode only, because the concurrent access to Thread::thread_id_ is introduced within a DCHECK_NE. -- You received this message because you are listed in the owner or CC fields of this issue, or because you starred this issue. You may adjust your issue notification preferences at: http://code.google.com/hosting/settings --~--~---------~--~----~------------~-------~--~----~ Automated mail from issue updates at http://crbug.com/ Subscription options: http://groups.google.com/group/chromium-bugs -~----------~----~----~----~------~----~------~--~---
