Bug 187152 - ASSERT(m_dictionaryStack.size() == 1) assertion hit in ~KeyedDecoderCF() when decoding fails
Summary: ASSERT(m_dictionaryStack.size() == 1) assertion hit in ~KeyedDecoderCF() when...
Status: RESOLVED FIXED
Alias: None
Product: WebKit
Classification: Unclassified
Component: WebCore Misc. (show other bugs)
Version: WebKit Nightly Build
Hardware: Unspecified Unspecified
: P2 Normal
Assignee: Chris Dumez
URL:
Keywords: InRadar
Depends on:
Blocks:
 
Reported: 2018-06-28 12:48 PDT by Chris Dumez
Modified: 2018-07-05 09:07 PDT (History)
6 users (show)

See Also:


Attachments
Patch (2.95 KB, patch)
2018-06-28 12:56 PDT, Chris Dumez
no flags Details | Formatted Diff | Diff
Archive of layout-test-results from ews205 for win-future (12.97 MB, application/zip)
2018-06-28 20:15 PDT, EWS Watchlist
no flags Details
Patch (2.22 KB, patch)
2018-07-05 08:25 PDT, Chris Dumez
no flags Details | Formatted Diff | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Chris Dumez 2018-06-28 12:48:37 PDT
ASSERT(m_dictionaryStack.size() == 1) assertion hit in ~KeyedDecoderCF() when decoding fails:
Thread 5 Crashed:: Dispatch queue: WebResourceLoadStatisticsStore Process Data Queue
0   com.apple.JavaScriptCore      	0x00000001126ba2b0 WTFCrash + 16 (Assertions.cpp:267)
1   com.apple.WebCore             	0x000000011e6c16a0 WebCore::KeyedDecoderCF::~KeyedDecoderCF() + 96 (KeyedDecoderCF.cpp:53)
2   com.apple.WebCore             	0x000000011e6c1955 WebCore::KeyedDecoderCF::~KeyedDecoderCF() + 21 (KeyedDecoderCF.cpp:57)
3   com.apple.WebCore             	0x000000011e6c1979 WebCore::KeyedDecoderCF::~KeyedDecoderCF() + 25 (KeyedDecoderCF.cpp:52)
4   com.apple.WebKit              	0x00000001177bb51e WebKit::ResourceLoadStatisticsPersistentStorage::populateMemoryStoreFromDisk() + 926 (memory:2598)
5   com.apple.WebKit              	0x00000001177bb13d WebKit::ResourceLoadStatisticsPersistentStorage::ResourceLoadStatisticsPersistentStorage(WebKit::ResourceLoadStatisticsMemoryStore&, WTF::WorkQueue&, WTF::String const&, WebKit::ResourceLoadStatisticsPersistentStorage::IsReadOnly) + 365 (ResourceLoadStatisticsPersistentStorage.cpp:96)
6   com.apple.WebKit              	0x00000001177bbaf5 WebKit::ResourceLoadStatisticsPersistentStorage::ResourceLoadStatisticsPersistentStorage(WebKit::ResourceLoadStatisticsMemoryStore&, WTF::WorkQueue&, WTF::String const&, WebKit::ResourceLoadStatisticsPersistentStorage::IsReadOnly) + 53 (ResourceLoadStatisticsPersistentStorage.cpp:97)
7   com.apple.WebKit              	0x0000000117fa8046 WebKit::WebResourceLoadStatisticsStore::WebResourceLoadStatisticsStore(WTF::String const&, WTF::Function<void (WTF::String const&)>&&, bool, WTF::Function<void (WTF::Vector<WTF::String, 0ul, WTF::CrashOnOverflow, 16ul> const&, WTF::Vector<WTF::String, 0ul, WTF::CrashOnOverflow, 16ul> const&, WTF::Vector<WTF::String, 0ul, WTF::CrashOnOverflow, 16ul> const&, WebKit::ShouldClearFirst, WTF::CompletionHandler<void ()>&&)>&&, WTF::Function<void (WTF::String const&, WTF::String const&, unsigned long long, unsigned long long, WTF::Function<void (bool)>&&)>&&, WTF::Function<void (WTF::String const&, WTF::String const&, std::optional<unsigned long long>, unsigned long long, WTF::Function<void (bool)>&&)>&&, WTF::Function<void ()>&&, WTF::Function<void (WTF::Vector<WTF::String, 0ul, WTF::CrashOnOverflow, 16ul> const&)>&&)::$_3::operator()() const + 1350 (memory:3078)
8   com.apple.WebKit              	0x0000000117fa7a39 WTF::Function<void ()>::CallableWrapper<WebKit::WebResourceLoadStatisticsStore::WebResourceLoadStatisticsStore(WTF::String const&, WTF::Function<void (WTF::String const&)>&&, bool, WTF::Function<void (WTF::Vector<WTF::String, 0ul, WTF::CrashOnOverflow, 16ul> const&, WTF::Vector<WTF::String, 0ul, WTF::CrashOnOverflow, 16ul> const&, WTF::Vector<WTF::String, 0ul, WTF::CrashOnOverflow, 16ul> const&, WebKit::ShouldClearFirst, WTF::CompletionHandler<void ()>&&)>&&, WTF::Function<void (WTF::String const&, WTF::String const&, unsigned long long, unsigned long long, WTF::Function<void (bool)>&&)>&&, WTF::Function<void (WTF::String const&, WTF::String const&, std::optional<unsigned long long>, unsigned long long, WTF::Function<void (bool)>&&)>&&, WTF::Function<void ()>&&, WTF::Function<void (WTF::Vector<WTF::String, 0ul, WTF::CrashOnOverflow, 16ul> const&)>&&)::$_3>::call() + 25 (Function.h:101)
9   com.apple.JavaScriptCore      	0x00000001126df6fd WTF::Function<void ()>::operator()() const + 141 (Function.h:56)
10  com.apple.JavaScriptCore      	0x00000001127754b9 WTF::WorkQueue::dispatch(WTF::Function<void ()>&&)::$_0::operator()() const + 25 (WorkQueueCocoa.cpp:37)
11  com.apple.JavaScriptCore      	0x0000000112775490 WTF::BlockPtr<void ()> WTF::BlockPtr<void ()>::fromCallable<WTF::WorkQueue::dispatch(WTF::Function<void ()>&&)::$_0>(WTF::WorkQueue::dispatch(WTF::Function<void ()>&&)::$_0)::'lambda'(void*)::operator()(void*) const + 32 (BlockPtr.h:94)
12  com.apple.JavaScriptCore      	0x0000000112775468 WTF::BlockPtr<void ()> WTF::BlockPtr<void ()>::fromCallable<WTF::WorkQueue::dispatch(WTF::Function<void ()>&&)::$_0>(WTF::WorkQueue::dispatch(WTF::Function<void ()>&&)::$_0)::'lambda'(void*)::__invoke(void*) + 24 (BlockPtr.h:93)
13  libdispatch.dylib             	0x00007fff5cd66803 _dispatch_call_block_and_release + 12
14  libdispatch.dylib             	0x00007fff5cd5f9d6 _dispatch_client_callout + 8
15  libdispatch.dylib             	0x00007fff5cd72c72 _dispatch_lane_serial_drain + 618
16  libdispatch.dylib             	0x00007fff5cd73732 _dispatch_lane_invoke + 388
17  libdispatch.dylib             	0x00007fff5cd79eb8 _dispatch_workloop_worker_thread + 603
18  libsystem_pthread.dylib       	0x00007fff5cf9e8da _pthread_wqthread + 409
19  libsystem_pthread.dylib       	0x00007fff5cf9e6d1 start_wqthread + 13
Comment 1 Chris Dumez 2018-06-28 12:56:39 PDT
Created attachment 343836 [details]
Patch
Comment 2 EWS Watchlist 2018-06-28 20:15:10 PDT
Comment on attachment 343836 [details]
Patch

Attachment 343836 [details] did not pass win-ews (win):
Output: https://webkit-queues.webkit.org/results/8377413

New failing tests:
http/tests/security/canvas-remote-read-remote-video-redirect.html
Comment 3 EWS Watchlist 2018-06-28 20:15:21 PDT
Created attachment 343889 [details]
Archive of layout-test-results from ews205 for win-future

The attached test failures were seen while running run-webkit-tests on the win-ews.
Bot: ews205  Port: win-future  Platform: CYGWIN_NT-6.1-2.9.0-0.318-5-3-x86_64-64bit
Comment 4 Sam Weinig 2018-07-03 12:52:58 PDT
Comment on attachment 343836 [details]
Patch

View in context: https://bugs.webkit.org/attachment.cgi?id=343836&action=review

> Source/WebCore/platform/cf/KeyedDecoderCF.cpp:53
> +    WTFLogAlways("m_dictionaryStack size is %lu", m_dictionaryStack.size());

Do we really want to always log this?
Comment 5 Chris Dumez 2018-07-03 13:02:46 PDT
Comment on attachment 343836 [details]
Patch

View in context: https://bugs.webkit.org/attachment.cgi?id=343836&action=review

>> Source/WebCore/platform/cf/KeyedDecoderCF.cpp:53
>> +    WTFLogAlways("m_dictionaryStack size is %lu", m_dictionaryStack.size());
> 
> Do we really want to always log this?

Lol no, Will drop this logging before landing.
Comment 6 Brent Fulgham 2018-07-03 19:35:50 PDT
Comment on attachment 343836 [details]
Patch

R=me
Comment 7 Chris Dumez 2018-07-05 08:25:42 PDT
Created attachment 344329 [details]
Patch
Comment 8 WebKit Commit Bot 2018-07-05 09:05:32 PDT
Comment on attachment 344329 [details]
Patch

Clearing flags on attachment: 344329

Committed r233521: <https://trac.webkit.org/changeset/233521>
Comment 9 WebKit Commit Bot 2018-07-05 09:05:34 PDT
All reviewed patches have been landed.  Closing bug.
Comment 10 Radar WebKit Bug Importer 2018-07-05 09:07:33 PDT
<rdar://problem/41850303>