WebKit Bugzilla
New
Browse
Log In
×
Sign in with GitHub
or
Remember my login
Create Account
·
Forgot Password
Forgotten password account recovery
RESOLVED FIXED
220394
Use smart pointers in UIDelegate and NavigationState
https://bugs.webkit.org/show_bug.cgi?id=220394
Summary
Use smart pointers in UIDelegate and NavigationState
Alex Christensen
Reported
2021-01-06 17:47:55 PST
Protect WebPageProxy in didFinishLoadForFrame
Attachments
Patch
(1.69 KB, patch)
2021-01-06 17:49 PST
,
Alex Christensen
no flags
Details
Formatted Diff
Diff
Patch
(151.48 KB, patch)
2021-01-07 10:38 PST
,
Alex Christensen
ews-feeder
: commit-queue-
Details
Formatted Diff
Diff
Patch
(151.67 KB, patch)
2021-01-07 10:53 PST
,
Alex Christensen
ews-feeder
: commit-queue-
Details
Formatted Diff
Diff
Patch
(157.76 KB, patch)
2021-01-07 11:25 PST
,
Alex Christensen
ews-feeder
: commit-queue-
Details
Formatted Diff
Diff
Patch
(149.43 KB, patch)
2021-01-07 12:18 PST
,
Alex Christensen
no flags
Details
Formatted Diff
Diff
Patch
(151.37 KB, patch)
2021-01-07 13:53 PST
,
Alex Christensen
no flags
Details
Formatted Diff
Diff
Show Obsolete
(5)
View All
Add attachment
proposed patch, testcase, etc.
Alex Christensen
Comment 1
2021-01-06 17:49:22 PST
Created
attachment 417144
[details]
Patch
Alex Christensen
Comment 2
2021-01-06 17:49:25 PST
<
rdar://problem/72496374
>
Chris Dumez
Comment 3
2021-01-07 08:31:45 PST
Comment on
attachment 417144
[details]
Patch View in context:
https://bugs.webkit.org/attachment.cgi?id=417144&action=review
> Source/WebKit/UIProcess/WebPageProxy.cpp:4770 > + auto protectedThis = makeRef(*this);
This is unnecessary in functions called via IPC. We solved it at a global level years ago. If you look at WebPageProxy::didReceiveMessage() in generated code, you will see: auto protectedThis = makeRef(*this); We protect the WebPageProxy while calling every function due to an IPC message.
Alex Christensen
Comment 4
2021-01-07 10:38:37 PST
Created
attachment 417187
[details]
Patch
Alex Christensen
Comment 5
2021-01-07 10:53:05 PST
Created
attachment 417189
[details]
Patch
Alex Christensen
Comment 6
2021-01-07 11:25:07 PST
Created
attachment 417192
[details]
Patch
Alex Christensen
Comment 7
2021-01-07 12:18:01 PST
Created
attachment 417198
[details]
Patch
Geoffrey Garen
Comment 8
2021-01-07 12:50:07 PST
Comment on
attachment 417198
[details]
Patch r=me Smart pointer is definitely better than raw pointer here. Would be nice in the future just to make this lifetime mismatch impossible.
Alex Christensen
Comment 9
2021-01-07 13:53:40 PST
Comment on
attachment 417198
[details]
Patch View in context:
https://bugs.webkit.org/attachment.cgi?id=417198&action=review
> Source/WebKit/UIProcess/Cocoa/UIDelegate.mm:408 > - return; > + return completionHandler(false);
Surprisingly this changed behavior in an undesirable way. Will revert.
Alex Christensen
Comment 10
2021-01-07 13:53:52 PST
Created
attachment 417209
[details]
Patch
EWS
Comment 11
2021-01-07 15:10:55 PST
Committed
r271264
: <
https://trac.webkit.org/changeset/271264
> All reviewed patches have been landed. Closing bug and clearing flags on
attachment 417209
[details]
.
Note
You need to
log in
before you can comment on or make changes to this bug.
Top of Page
Format For Printing
XML
Clone This Bug