-
Notifications
You must be signed in to change notification settings - Fork 24.1k
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
[Android] Crash: FileReaderModule.readAsText java.lang.NullPointerException #45277
Labels
Resolution: PR Submitted
A pull request with a fix has been provided.
Comments
|
Yup that's a valid bugreport 👍 Thanks for the reproducer @JinYuSha0 A fix is forthcoming |
cortinico
added a commit
to cortinico/react-native
that referenced
this issue
Jul 4, 2024
Summary: Fixes facebook#45277 This fixes an NPE reported in OSS if you do this call in JavaScript: ``` const fr = new FileReader(); fr.readAsText({}); ``` Changelog: [Android] [Fixed] - Fix NPE in FileReaderModule Differential Revision: D59372620
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Description
I see a lot of these crashes in Google Crashlytics:
Locate the following code:
https://github.com/facebook/react-native/blob/main/packages/react-native/ReactAndroid/src/main/java/com/facebook/react/modules/blob/FileReaderModule.java#L47
The judgment of blob is not very good.
Steps to reproduce
React Native Version
0.70.1
Affected Platforms
Runtime - Android
Output of
npx react-native info
Stacktrace or Logs
Reproducer
https://github.com/JinYuSha0/FileReaderReproducer
Screenshots and Videos
No response
The text was updated successfully, but these errors were encountered: