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

Crashed(ios): to call setSrc twice #963

Closed
masarusanjp opened this issue Mar 9, 2018 · 0 comments · Fixed by #974
Closed

Crashed(ios): to call setSrc twice #963

masarusanjp opened this issue Mar 9, 2018 · 0 comments · Fixed by #974

Comments

@masarusanjp
Copy link
Contributor

Related pr: #600

Crash occured at here:
https://github.com/react-native-community/react-native-video/blob/master/ios/RCTVideo.m#L735

Called from:
https://github.com/react-native-community/react-native-video/blob/master/ios/RCTVideo.m#L277

Because readyForDisplayKeyPath observer had been removed in removePlayerTimeObserver.
https://github.com/react-native-community/react-native-video/blob/master/ios/RCTVideo.m#L271

So, when calling removePlayerLayer, an exception occurred by removing readyForDisplayKeyPath in multiple.

CC: @awitherow

wildseansy pushed a commit to wildseansy/react-native-video that referenced this issue Mar 19, 2018
Bug happens when uri is changed for a video.

The fix:
Remove player layer before addPlayerItemObservers so _playerItemObserversSet is still set to NO if observers have already been removed.
@wildseansy wildseansy mentioned this issue Mar 19, 2018
wildseansy pushed a commit to wildseansy/react-native-video that referenced this issue Mar 19, 2018
Bug happens when uri is changed for a video.

The fix:
Remove player layer before addPlayerItemObservers so _playerItemObserversSet is still set to NO if observers have already been removed.
wildseansy pushed a commit to wildseansy/react-native-video that referenced this issue Mar 26, 2018
Bug happens when uri is changed for a video.

The fix:
Remove player layer before addPlayerItemObservers so _playerItemObserversSet is still set to NO if observers have already been removed.
davrosull added a commit to ACloudGuru/react-native-video that referenced this issue Apr 19, 2018
cobarx added a commit that referenced this issue Jun 4, 2018
jortegano pushed a commit to devtence/react-native-video that referenced this issue Jun 16, 2018
Bug happens when uri is changed for a video.

The fix:
Remove player layer before addPlayerItemObservers so _playerItemObserversSet is still set to NO if observers have already been removed.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant