Commit 65cbfbae authored by Mike Dougherty's avatar Mike Dougherty Committed by Commit Bot

[iOS] Ensure classes don’t retain injection receiver.

CRWJSInjectionReceiver shouldn’t be retained, except by CRWWebController. Update
other references to weak.

Bug: 1004321
Change-Id: I0c936b476fb65c8d1d2e0f0be6f5179257897aab
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/1807606
Commit-Queue: Mike Dougherty <michaeldo@chromium.org>
Reviewed-by: default avatarMoe Ahmadi <mahmadi@chromium.org>
Reviewed-by: default avatarVadym Doroshenko <dvadym@chromium.org>
Auto-Submit: Mike Dougherty <michaeldo@chromium.org>
Cr-Commit-Position: refs/heads/master@{#697248}
parent dc893b38
...@@ -28,7 +28,7 @@ ...@@ -28,7 +28,7 @@
@implementation JsAutofillManager { @implementation JsAutofillManager {
// The injection receiver used to evaluate JavaScript. // The injection receiver used to evaluate JavaScript.
CRWJSInjectionReceiver* _receiver; __weak CRWJSInjectionReceiver* _receiver;
} }
- (instancetype)initWithReceiver:(CRWJSInjectionReceiver*)receiver { - (instancetype)initWithReceiver:(CRWJSInjectionReceiver*)receiver {
......
...@@ -24,7 +24,7 @@ ...@@ -24,7 +24,7 @@
@implementation JsSuggestionManager { @implementation JsSuggestionManager {
// The injection receiver used to evaluate JavaScript. // The injection receiver used to evaluate JavaScript.
CRWJSInjectionReceiver* _receiver; __weak CRWJSInjectionReceiver* _receiver;
web::WebFramesManager* _webFramesManager; web::WebFramesManager* _webFramesManager;
} }
......
...@@ -75,7 +75,7 @@ NSString* JSONEscape(NSString* JSONString) { ...@@ -75,7 +75,7 @@ NSString* JSONEscape(NSString* JSONString) {
@implementation JsPasswordManager { @implementation JsPasswordManager {
// The injection receiver used to evaluate JavaScript. // The injection receiver used to evaluate JavaScript.
CRWJSInjectionReceiver* _receiver; __weak CRWJSInjectionReceiver* _receiver;
} }
- (instancetype)initWithReceiver:(CRWJSInjectionReceiver*)receiver { - (instancetype)initWithReceiver:(CRWJSInjectionReceiver*)receiver {
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment