Bug 174814 - [curl] ASSERTION FAILED: The string being removed is atomic in the string table of an other thread!
Summary: [curl] ASSERTION FAILED: The string being removed is atomic in the string tab...
Status: RESOLVED DUPLICATE of bug 174845
Alias: None
Product: WebKit
Classification: Unclassified
Component: Platform (show other bugs)
Version: WebKit Nightly Build
Hardware: Unspecified Unspecified
: P2 Normal
Assignee: Nobody
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2017-07-25 01:54 PDT by Fujii Hironori
Modified: 2017-07-26 02:02 PDT (History)
1 user (show)

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Fujii Hironori 2017-07-25 01:54:21 PDT
While using MiniBrowser of WinCairo port (trunk@219863, Debug build),
I see the following assertion failure.

> ASSERTION FAILED: The string being removed is atomic in the string table of an other thread!
> iterator != atomicStringTable.end()
> C:\webkit\ga\Source\WTF\wtf\text\AtomicStringImpl.cpp(483) : WTF::AtomicStringImpl::remove


> WTF.dll!WTFCrash() Line 278	C++
> WTF.dll!WTF::AtomicStringImpl::remove(WTF::AtomicStringImpl * string) Line 483	C++
> WTF.dll!WTF::StringImpl::~StringImpl() Line 118	C++
> [External Code]	
> WTF.dll!WTF::StringImpl::destroy(WTF::StringImpl * stringImpl) Line 144	C++
> WebKit.dll!WTF::StringImpl::deref() Line 566	C++
> WebKit.dll!WTF::derefIfNotNull<WTF::StringImpl>(WTF::StringImpl * ptr) Line 46	C++
> WebKit.dll!WTF::RefPtr<WTF::StringImpl>::~RefPtr<WTF::StringImpl>() Line 69	C++
> WebKit.dll!WTF::String::~String() Line 142	C++
> [External Code]	
> WebKit.dll!WebCore::ResourceHandleInternal::~ResourceHandleInternal() Line 52	C++
> [External Code]	
> WebKit.dll!WebCore::ResourceHandle::~ResourceHandle() Line 56	C++
> [External Code]	
> WebKit.dll!WTF::RefCounted<WebCore::ResourceHandle>::deref() Line 145	C++
> WebKit.dll!WTF::Ref<WebCore::ResourceHandle>::~Ref<WebCore::ResourceHandle>() Line 59	C++
> [External Code]	
> WTF.dll!WTF::Function<void __cdecl(void)>::operator=(void * __formal) Line 79	C++
> WTF.dll!WTF::dispatchFunctionsFromMainThread() Line 138	C++
> WTF.dll!WTF::ThreadingWindowWndProc(HWND__ * hWnd, unsigned int message, unsigned __int64 wParam, __int64 lParam) Line 47	C++
> [External Code]	
> WebKit.dll!WebKitMessageLoop::run(HACCEL__ * hAccelTable) Line 97	C++
> MiniBrowserLib.dll!wWinMain(HINSTANCE__ * hInstance, HINSTANCE__ * hPrevInstance, wchar_t * lpstrCmdLine, int nCmdShow) Line 189	C++
> MiniBrowserLib.dll!dllLauncherEntryPoint(HINSTANCE__ * hInstance, HINSTANCE__ * hPrevInstance, wchar_t * lpstrCmdLine, int nCmdShow) Line 908	C++
> MiniBrowser.exe!wWinMain(HINSTANCE__ * hInstance, HINSTANCE__ * hPrevInstance, wchar_t * lpstrCmdLine, int nCmdShow) Line 249	C++
> [External Code]
Comment 1 Fujii Hironori 2017-07-25 02:00:43 PDT
That string is "OK".

> WebKit.dll!WTF::String::~String() Line 142	C++
> [External Code]	
> WebKit.dll!WebCore::ResourceHandleInternal::~ResourceHandleInternal() Line 52	C++

~ResourceHandleInternal was calling WebCore::ResourceResponse::~ResourceResponse.
I don't know who was calling ~String().
Comment 2 Basuke Suzuki 2017-07-25 10:59:04 PDT
Okay. Thanks for reporting. Still ResourceHandle curl has bunch of mysterious behaviors which need to cleanup. One by one.
Comment 3 Fujii Hironori 2017-07-25 20:38:44 PDT
The type of ResourceResponseBase::m_httpStatusText is AtomicString.
ResourceHandleInternal::didReceiveHeaderLine calls setHTTPStatusText in the curl thread.
And, the AtomicString is destructed in main thread.
Comment 4 Fujii Hironori 2017-07-26 02:02:45 PDT

*** This bug has been marked as a duplicate of bug 174845 ***