[Webkit-unassigned] [Bug 69942] When an API test fails, TestWebKitAPI crashes

bugzilla-daemon at webkit.org bugzilla-daemon at webkit.org
Wed Dec 21 09:30:42 PST 2011


https://bugs.webkit.org/show_bug.cgi?id=69942





--- Comment #13 from David Kilzer (ddkilzer) <ddkilzer at webkit.org>  2011-12-21 09:30:42 PST ---
(In reply to comment #12)
> This change fixed crashes in Release builds when a WTF::String() comparison fails (and when compiling with "-g -O0"), but I'm still seeing crashes on Debug builds.  Investigating.

LOL!  Looks like threading isn't being initialized properly in TestWebKitAPI for a new test I wrote (an assertion is firing):

Thread 0 Crashed:: Dispatch queue: com.apple.main-thread
0   com.apple.JavaScriptCore          0x000000010792e203 WTF::isMainThread() + 195 (MainThreadMac.mm:144)
1   com.apple.WebCore                 0x00000001098a3efd _ZN7WebCoreL22buildBaseTextCodecMapsEv + 13 (TextEncodingRegistry.cpp:213)
2   com.apple.WebCore                 0x00000001098a3e2a WebCore::atomicCanonicalTextEncodingName(char const*) + 74 (TextEncodingRegistry.cpp:338)
3   com.apple.WebCore                 0x00000001098a2c21 WebCore::TextEncoding::TextEncoding(char const*) + 33 (TextEncoding.cpp:55)
4   com.apple.WebCore                 0x00000001098a2bed WebCore::TextEncoding::TextEncoding(char const*) + 29 (TextEncoding.cpp:58)
5   com.apple.WebCore                 0x00000001098a3598 WebCore::UTF8Encoding() + 40 (TextEncoding.cpp:250)
6   com.apple.WebCore                 0x000000010928e7b4 WebCore::decodeURLEscapeSequences(WTF::String const&) + 36 (KURL.cpp:919)
7   com.apple.WebCore                 0x000000010928e77a WebCore::KURL::host() const + 90 (KURL.cpp:586)
8   TestWebKitAPI                     0x0000000106073fbf TestWebKitAPI::WebCore_KURLConstCharConstructor_Test::TestBody() + 2015 (KURL.cpp:54)
9   TestWebKitAPI                     0x000000010607e7ca testing::Test::Run() + 154
10  TestWebKitAPI                     0x000000010607f0cd testing::internal::TestInfoImpl::Run() + 189
11  TestWebKitAPI                     0x000000010607f8fd testing::TestCase::Run() + 205
12  TestWebKitAPI                     0x00000001060849e9 testing::internal::UnitTestImpl::RunAllTests() + 793
13  TestWebKitAPI                     0x00000001060846c9 testing::UnitTest::Run() + 25
14  TestWebKitAPI                     0x0000000105fe9870 TestWebKitAPI::TestsController::run(int, char**) + 48 (TestsController.cpp:51)
15  TestWebKitAPI                     0x0000000105fe96e9 main + 121 (main.mm:35)
16  TestWebKitAPI                     0x0000000105fe8ca4 start + 52

The assertion is here:

bool isMainThread()
{
    if (mainThreadEstablishedAsPthreadMain) {
        ASSERT(!mainThreadPthread);
        return pthread_main_np();
    }

    ASSERT(mainThreadPthread); // Line 144
    return pthread_equal(pthread_self(), mainThreadPthread);
}

That's a separate bug.  I'll post the patch for this bug.

-- 
Configure bugmail: https://bugs.webkit.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.



More information about the webkit-unassigned mailing list