Non-web clients may delete website data records. In such cases the shared observer will not have a store to clear so we should check that it exists.
rdar://problem/31258505
Created attachment 305940 [details] Patch
Comment on attachment 305940 [details] Patch View in context: https://bugs.webkit.org/attachment.cgi?id=305940&action=review r=me > Source/WebCore/loader/ResourceLoadObserver.cpp:74 > + m_store->clearInMemoryAndPersistent(); We should audit the code for other cases like this, since we now realize there are other WK2 clients that are not browsers.
(In reply to Brent Fulgham from comment #3) > Comment on attachment 305940 [details] > Patch > > View in context: > https://bugs.webkit.org/attachment.cgi?id=305940&action=review > > r=me Thanks! > > Source/WebCore/loader/ResourceLoadObserver.cpp:74 > > + m_store->clearInMemoryAndPersistent(); > > We should audit the code for other cases like this, since we now realize > there are other WK2 clients that are not browsers. Agreed. The root cause is the static sharedObserver() getter which anyone can call, no matter how they’ve set up the WebsiteDataStore. I'll land this and take another look.
Comment on attachment 305940 [details] Patch Clearing flags on attachment: 305940 Committed r214669: <http://trac.webkit.org/changeset/214669>
All reviewed patches have been landed. Closing bug.