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 Array Out of Bounds crash if no video tracks present #1413

Merged
merged 1 commit into from
Jan 4, 2019

Conversation

cobarx
Copy link
Contributor

@cobarx cobarx commented Jan 4, 2019

This was caused by the video track auto selection code assuming there was always a video track group. On audio only files, there is no video group so we get an out of bounds. The code now checks to ensure that group 0 actually exists.

In the multi-track videos I tested, auto-track selection works properly, but I'm not sure if there are any situations where you might have multiple video track groups. I believe this would only happen with an MP4 that has multiple embedded video streams.

Fixes #1408

@cobarx cobarx merged commit fd90167 into master Jan 4, 2019
@cobarx cobarx deleted the bugfix/no-video-out-of-bounds branch January 4, 2019 06:13
beauner69 pushed a commit to beauner69/react-native-video that referenced this pull request Oct 10, 2019
…ugfix/no-video-out-of-bounds

Fix Array Out of Bounds crash if no video tracks present

(rebased from commit fd90167)
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 this pull request may close these issues.

1 participant