[SCM] WebKit Debian packaging branch, webkit-1.3, updated. upstream/1.3.7-4207-g178b198
dpranke at chromium.org
dpranke at chromium.org
Sun Feb 20 23:12:24 UTC 2011
The following commit has been merged in the webkit-1.3 branch:
commit 3fd9a5931e303da0cd2d8c03636907adfbff8fbd
Author: dpranke at chromium.org <dpranke at chromium.org@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Date: Tue Jan 18 23:21:03 2011 +0000
2011-01-18 Dirk Pranke <dpranke at chromium.org>
Reviewed by Mihai Parparita.
Fix a small race condition that could cause the unit tests for
new-run-webkit-tests to fail in a multithreaded environment.
There was a small window in the code where one thread would
check to see if a thread had raised an exception, do something,
and then check to see if the thread was alive. If the other
thread raised an exception and exited in between these two
steps, the exception would be lost. Flipping the order of the
two checks fixes the race, since we will now always check for an
exception on the thread before exiting.
https://bugs.webkit.org/show_bug.cgi?id=51579
* Scripts/webkitpy/layout_tests/layout_package/message_broker.py:
git-svn-id: http://svn.webkit.org/repository/webkit/trunk@76073 268f45cc-cd09-0410-ab3c-d52691b4dbfc
diff --git a/Tools/ChangeLog b/Tools/ChangeLog
index bcdcb33..3601d3d 100644
--- a/Tools/ChangeLog
+++ b/Tools/ChangeLog
@@ -1,3 +1,21 @@
+2011-01-18 Dirk Pranke <dpranke at chromium.org>
+
+ Reviewed by Mihai Parparita.
+
+ Fix a small race condition that could cause the unit tests for
+ new-run-webkit-tests to fail in a multithreaded environment.
+ There was a small window in the code where one thread would
+ check to see if a thread had raised an exception, do something,
+ and then check to see if the thread was alive. If the other
+ thread raised an exception and exited in between these two
+ steps, the exception would be lost. Flipping the order of the
+ two checks fixes the race, since we will now always check for an
+ exception on the thread before exiting.
+
+ https://bugs.webkit.org/show_bug.cgi?id=51579
+
+ * Scripts/webkitpy/layout_tests/layout_package/message_broker.py:
+
2011-01-18 Eric Seidel <eric at webkit.org>
Reviewed by Adam Barth.
diff --git a/Tools/Scripts/webkitpy/layout_tests/layout_package/message_broker.py b/Tools/Scripts/webkitpy/layout_tests/layout_package/message_broker.py
index e0ca8db..481c617 100644
--- a/Tools/Scripts/webkitpy/layout_tests/layout_package/message_broker.py
+++ b/Tools/Scripts/webkitpy/layout_tests/layout_package/message_broker.py
@@ -144,6 +144,13 @@ class MultiThreadedBroker(WorkerMessageBroker):
some_thread_is_alive = False
t = time.time()
for thread in threads:
+ if thread.isAlive():
+ some_thread_is_alive = True
+ next_timeout = thread.next_timeout()
+ if next_timeout and t > next_timeout:
+ log_wedged_worker(thread.getName(), thread.id())
+ thread.clear_next_timeout()
+
exception_info = thread.exception_info()
if exception_info is not None:
# Re-raise the thread's exception here to make it
@@ -152,13 +159,6 @@ class MultiThreadedBroker(WorkerMessageBroker):
# to have passed.
raise exception_info[0], exception_info[1], exception_info[2]
- if thread.isAlive():
- some_thread_is_alive = True
- next_timeout = thread.next_timeout()
- if next_timeout and t > next_timeout:
- log_wedged_worker(thread.getName(), thread.id())
- thread.clear_next_timeout()
-
self._test_runner.update()
if some_thread_is_alive:
--
WebKit Debian packaging
More information about the Pkg-webkit-commits
mailing list