Title: [218724] trunk/Source/WebKit2
- Revision
- 218724
- Author
- [email protected]
- Date
- 2017-06-22 15:24:05 -0700 (Thu, 22 Jun 2017)
Log Message
isMainThread() assertions in CallbackMap are incorrectly failing on some iOS apps
https://bugs.webkit.org/show_bug.cgi?id=173738
<rdar://problem/32923933>
Reviewed by Brady Eidson.
The assertions hit on certain iOS apps even though the crash traces clearly
show them on the main thread. We have verified locally that RunLoop::isMain()
propertly return true in this case (while WTF::isMainThread() returns false).
Update the assertions to use RunLoop::isMain() instead.
* UIProcess/GenericCallback.h:
(WebKit::CallbackMap::put):
(WebKit::CallbackMap::take):
(WebKit::CallbackMap::invalidate):
Modified Paths
Diff
Modified: trunk/Source/WebKit2/ChangeLog (218723 => 218724)
--- trunk/Source/WebKit2/ChangeLog 2017-06-22 22:12:26 UTC (rev 218723)
+++ trunk/Source/WebKit2/ChangeLog 2017-06-22 22:24:05 UTC (rev 218724)
@@ -1,3 +1,21 @@
+2017-06-22 Chris Dumez <[email protected]>
+
+ isMainThread() assertions in CallbackMap are incorrectly failing on some iOS apps
+ https://bugs.webkit.org/show_bug.cgi?id=173738
+ <rdar://problem/32923933>
+
+ Reviewed by Brady Eidson.
+
+ The assertions hit on certain iOS apps even though the crash traces clearly
+ show them on the main thread. We have verified locally that RunLoop::isMain()
+ propertly return true in this case (while WTF::isMainThread() returns false).
+ Update the assertions to use RunLoop::isMain() instead.
+
+ * UIProcess/GenericCallback.h:
+ (WebKit::CallbackMap::put):
+ (WebKit::CallbackMap::take):
+ (WebKit::CallbackMap::invalidate):
+
2017-06-22 Daniel Bates <[email protected]>
Make FrameLoadRequest a move-only type
Modified: trunk/Source/WebKit2/UIProcess/GenericCallback.h (218723 => 218724)
--- trunk/Source/WebKit2/UIProcess/GenericCallback.h 2017-06-22 22:12:26 UTC (rev 218723)
+++ trunk/Source/WebKit2/UIProcess/GenericCallback.h 2017-06-22 22:24:05 UTC (rev 218724)
@@ -182,7 +182,7 @@
public:
uint64_t put(Ref<CallbackBase>&& callback)
{
- RELEASE_ASSERT(isMainThread());
+ RELEASE_ASSERT(RunLoop::isMain());
uint64_t callbackID = callback->callbackID();
RELEASE_ASSERT(callbackID);
RELEASE_ASSERT(!m_map.contains(callbackID));
@@ -211,7 +211,7 @@
RefPtr<T> take(uint64_t callbackID)
{
RELEASE_ASSERT(callbackID);
- RELEASE_ASSERT(isMainThread());
+ RELEASE_ASSERT(RunLoop::isMain());
auto base = m_map.take(callbackID);
if (!base)
return nullptr;
@@ -221,7 +221,7 @@
void invalidate(CallbackBase::Error error)
{
- RELEASE_ASSERT(isMainThread());
+ RELEASE_ASSERT(RunLoop::isMain());
invalidateCallbackMap(m_map, error);
}
_______________________________________________
webkit-changes mailing list
[email protected]
https://lists.webkit.org/mailman/listinfo/webkit-changes