[Webkit-unassigned] [Bug 144824] New: [GTK] WTF_WorkQueue.Simple test fails due to assumptions about reference count
bugzilla-daemon at webkit.org
bugzilla-daemon at webkit.org
Fri May 8 18:50:54 PDT 2015
https://bugs.webkit.org/show_bug.cgi?id=144824
Bug ID: 144824
Summary: [GTK] WTF_WorkQueue.Simple test fails due to
assumptions about reference count
Classification: Unclassified
Product: WebKit
Version: 528+ (Nightly build)
Hardware: PC
OS: Linux
Status: NEW
Severity: Normal
Priority: P2
Component: Tools / Tests
Assignee: webkit-unassigned at lists.webkit.org
Reporter: mcatanzaro at igalia.com
**FAIL** WTF_WorkQueue.Simple
../../Tools/TestWebKitAPI/Tests/WTF/WorkQueue.cpp:57
Value of: initialRefCount
Actual: 2
Expected: 1
This is not a bug: we need the second ref to keep the WorkQueue alive in the lambda function where the main loop runs in another thread, in WorkQueue::platformInitialize:
RefPtr<WorkQueue> protector(this);
m_workQueueThread = createThread(threadName, [protector] {
g_main_context_push_thread_default(protector->m_eventContext.get());
g_main_loop_run(protector->m_eventLoop.get());
g_main_context_pop_thread_default(protector->m_eventContext.get());
});
Since we need to keep the WorkQueue alive in another thread, I think the only option is to change the test, not the implementation. CC Brent since he wrote this test. We could guard the reference count checks with #if !PLATFORM(GTK), or just remove the checks completely.
--
You are receiving this mail because:
You are the assignee for the bug.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.webkit.org/pipermail/webkit-unassigned/attachments/20150509/faf6e01e/attachment.html>
More information about the webkit-unassigned
mailing list