Bug 218599 - Store WeakPtr<Frame> instead of Frame*
Summary: Store WeakPtr<Frame> instead of Frame*
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-11-04 20:31 PST by Alex Christensen
Modified: 2021-03-26 23:27 PDT (History)
18 users (show)

See Also:


Attachments
Patch (43.87 KB, patch)
2020-11-04 20:31 PST, Alex Christensen
no flags Details | Formatted Diff | Diff
Patch (44.54 KB, patch)
2020-11-04 21:03 PST, Alex Christensen
youennf: review+
ews-feeder: commit-queue-
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-11-04 20:31:00 PST
Store WeakPtr<Frame> instead of Frame*
Comment 1 Alex Christensen 2020-11-04 20:31:55 PST
Created attachment 413244 [details]
Patch
Comment 2 Alex Christensen 2020-11-04 21:03:53 PST
Created attachment 413247 [details]
Patch
Comment 3 EWS Watchlist 2020-11-04 21:05:03 PST
Thanks for the patch. If this patch contains new public API please make sure it follows the guidelines for new WebKit2 GTK+ API. See https://trac.webkit.org/wiki/WebKitGTK/AddingNewWebKit2API
Comment 4 youenn fablet 2020-11-05 08:11:29 PST
Comment on attachment 413247 [details]
Patch

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

> Source/WebCore/bindings/js/WindowProxy.h:53
> +    WEBCORE_EXPORT AbstractFrame* frame() const;

Why not keeping it inline?
Comment 5 Alex Christensen 2020-11-05 08:34:23 PST
Comment on attachment 413247 [details]
Patch

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

>> Source/WebCore/bindings/js/WindowProxy.h:53
>> +    WEBCORE_EXPORT AbstractFrame* frame() const;
> 
> Why not keeping it inline?

That would require including AbstractFrame.h to build successfully.
Comment 6 EWS 2020-11-05 08:46:34 PST
Tools/Scripts/svn-apply failed to apply attachment 413247 [details] to trunk.
Please resolve the conflicts and upload a new patch.
Comment 7 Alex Christensen 2020-11-05 08:55:03 PST
http://trac.webkit.org/r269435
Comment 8 Radar WebKit Bug Importer 2020-11-05 08:56:20 PST
<rdar://problem/71079886>
Comment 9 Truitt Savell 2020-11-05 09:15:12 PST
It looks like the changes in https://trac.webkit.org/changeset/269435/webkit

broke Mac builds builds:
https://build.webkit.org/builders/Apple-BigSur-Release-Build/builds/2839

./loader/FrameLoader.cpp:389:12: error: no viable conversion from returned value of type 'WeakPtr<WebCore::Frame>' to function return type 'WebCore::Frame *'
./loader/FrameLoader.cpp:394:12: error: no viable conversion from returned value of type 'const WeakPtr<WebCore::Frame>' to function return type 'const WebCore::Frame *'
Comment 10 Alex Christensen 2020-11-05 09:20:52 PST
https://trac.webkit.org/changeset/269439/webkit