Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix videoplayer crash in release mode #1934

Merged
merged 1 commit into from Nov 15, 2019

Conversation

@minggo
Copy link
Contributor

minggo commented Nov 14, 2019

崩溃的调用顺序是这样的:

VideoPlayer::~VideoPlayer() -> UIVideoViewWrapperIos.dealloc() -> UIVideoViewWrapperIos.clean() -> UIVideoViewWrapperIos.stop() -> VideoPlayer::onPlayEvent()

也就是说 VideoPlayer 的析构函数会调用到事件监听的回调函数,但这时的事件监听者可能已经释放了,所以不在析构时去调用监听函数。

@cocos-robot cocos-robot changed the base branch from v2.1.4-release to v2.2.1-release Nov 15, 2019
Copy link
Contributor

cocos-robot left a comment

@minggo, v2.1.4-release branch will be deleted, so we edited the base branch to v2.2.1-release, or this PR will be killed by GitHub.
Please review the commits history to ensure that the PR does not polluted by unneeded commits from your origin branch.
If you need to merge to other branch, you can first click the Edit button on the right side of the PR title, then switch the base branch.
If necessary, welcome to resubmit a new PR. Thanks!

@minggo minggo merged commit 3af792e into cocos-creator:v2.2.1-release Nov 15, 2019
1 check passed
1 check passed
continuous-integration/travis-ci/pr The Travis CI build passed
Details
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
2 participants
You can’t perform that action at this time.