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

Make seek() throw an exception when using NaN value #1283

Merged
merged 1 commit into from
Nov 14, 2018
Merged

Make seek() throw an exception when using NaN value #1283

merged 1 commit into from
Nov 14, 2018

Conversation

laurent22
Copy link
Contributor

When seek() is used with a NaN value, a very hard to debug error is generated somewhere deep in React Native, which makes it hard to find the cause of the error (especially when the seek value is the result of a calculation that goes wrong in some cases but not others):

image

This pull request improves this by throwing an error early, which makes the issue clearer and provides a stack trace in user space:

image

@cobarx
Copy link
Contributor

cobarx commented Nov 14, 2018

Ok this makes a lot of sense, going ahead and merging this is a big improvement over the arcane error. Thanks.

@cobarx cobarx merged commit cbf96c2 into TheWidlarzGroup:master Nov 14, 2018
beauner69 pushed a commit to beauner69/react-native-video that referenced this pull request Oct 10, 2019
Make seek() throw an exception when using NaN value

(rebased from commit cbf96c2)
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.

2 participants