Bug 213636 - WKHTTPCookieStore.setCookie should flush the cookies to disk before calling completion handler when we are using the UIProcess's default cookie storage
Summary: WKHTTPCookieStore.setCookie should flush the cookies to disk before calling c...
Status: RESOLVED FIXED
Alias: None
Product: WebKit
Classification: Unclassified
Component: New Bugs (show other bugs)
Version: WebKit Nightly Build
Hardware: Unspecified Unspecified
: P2 Normal
Assignee: Alex Christensen
URL:
Keywords: InRadar
Depends on:
Blocks:
 
Reported: 2020-06-25 20:58 PDT by Alex Christensen
Modified: 2020-08-14 18:44 PDT (History)
2 users (show)

See Also:


Attachments
Patch (6.80 KB, patch)
2020-06-25 20:59 PDT, Alex Christensen
no flags Details | Formatted Diff | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Alex Christensen 2020-06-25 20:58:59 PDT
WKHTTPCookieStore.setCookie should flush the cookies to disk before calling completion handler when we are using the UIProcess's default cookie storage
Comment 1 Alex Christensen 2020-06-25 20:59:53 PDT
Created attachment 402847 [details]
Patch
Comment 2 EWS 2020-06-25 21:36:24 PDT
Committed r263551: <https://trac.webkit.org/changeset/263551>

All reviewed patches have been landed. Closing bug and clearing flags on attachment 402847 [details].
Comment 3 Radar WebKit Bug Importer 2020-06-25 21:37:13 PDT
<rdar://problem/64789854>
Comment 4 Alex Christensen 2020-08-14 18:04:42 PDT
Comment on attachment 402847 [details]
Patch

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

> Source/WebKit/UIProcess/API/Cocoa/APIHTTPCookieStoreCocoa.mm:42
> +    ASSERT(RunLoop::isMain());
> +    [[NSHTTPCookieStorage sharedHTTPCookieStorage] _saveCookies:makeBlockPtr([completionHandler = WTFMove(completionHandler)]() mutable {

This being on the main thread caused hangs which I believe were resolved with http://trac.webkit.org/r264613
Comment 5 Alex Christensen 2020-08-14 18:44:23 PDT
Reverting in https://bugs.webkit.org/show_bug.cgi?id=215530