Skip to content
This repository has been archived by the owner on Feb 22, 2023. It is now read-only.

[In_app_purchase] fix requesthandler crash #1199

Merged
merged 43 commits into from Feb 14, 2019

Conversation

cyanglaz
Copy link
Contributor

The FIAPRequestHandler is destroyed when exiting the function. Since FIAPRequestHandler is the delegate, when SKProductRequest tries to execute the delegate method, it will not be able to find the delegate. Hence the crash.

Adding a set to hold strong reference of the FIAPRequestHandler until it is complete fix the crash.

@cyanglaz
Copy link
Contributor Author

Should be reviewed after #1169 has landed

Copy link
Contributor

@mklim mklim left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@cyanglaz cyanglaz merged commit 0e72ca5 into flutter:master Feb 14, 2019
@cyanglaz cyanglaz deleted the iap_fix_requesthandler_crash branch February 15, 2019 18:20
andreidiaconu pushed a commit to andreidiaconu/plugins that referenced this pull request Feb 17, 2019
The FIAPRequestHandler is destroyed when exiting the function. Since FIAPRequestHandler is the delegate, when SKProductRequest tries to execute the delegate method, it will not be able to find the delegate. Hence the crash.

Adding a set to hold strong reference of the FIAPRequestHandler until it is complete fix the crash.
andreidiaconu added a commit to andreidiaconu/plugins that referenced this pull request Feb 17, 2019
karantanwar pushed a commit to karantanwar/plugins that referenced this pull request Feb 19, 2019
The FIAPRequestHandler is destroyed when exiting the function. Since FIAPRequestHandler is the delegate, when SKProductRequest tries to execute the delegate method, it will not be able to find the delegate. Hence the crash.

Adding a set to hold strong reference of the FIAPRequestHandler until it is complete fix the crash.
karantanwar pushed a commit to karantanwar/plugins that referenced this pull request Feb 19, 2019
The FIAPRequestHandler is destroyed when exiting the function. Since FIAPRequestHandler is the delegate, when SKProductRequest tries to execute the delegate method, it will not be able to find the delegate. Hence the crash.

Adding a set to hold strong reference of the FIAPRequestHandler until it is complete fix the crash.
@cyanglaz cyanglaz changed the title Iap fix requesthandler crash [In_app_purchase] fix requesthandler crash Feb 22, 2019
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
Projects
None yet
3 participants