-
-
Notifications
You must be signed in to change notification settings - Fork 2.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] App crash when onCancel is fired a lot of times #142
Comments
The |
I'm not able to reproduce. Tested on simulator api 23 and on real device api 17. What is your device ? |
I've got the problem on a OnePlus One (android 5.1) and a Nexus 5 (android 6) |
Tested on a Nexus 5 Android 6.0 still not able to reproduce... |
Maybe it can't be reproduce on RN 0.21. I will update and try it a again. |
This happened to me when i was trying to push the same map to a WritableArray twice by mistake in a loop. for eg. Bad code: WritableArray array = Arguments.createArray();
WritableMap map = Arguments.createMap();
while (condition) {
map.putString("somevalue", value);
array.pushMap(map);
} The code should have been: WritableArray array = Arguments.createArray();
while (condition) {
WritableMap map = Arguments.createMap();
map.putString("somevalue", value);
array.pushMap(map);
} As you can see in the bad example, the variable It seems the WritableArray is aware of the references of the objects and doesn't allow you to add a map twice. hope this helps or gives some insight |
@lwhiteley does that fix the crash? Want to submit a PR? |
I just made a little update in the project to fix this. As @lwhiteley just tell. Hope this will fix the issue ! |
No response, i close. |
Hello,
I might have a little problem with this code (at least, I think):
which could cause this error when I click at multiples times outside the popup:
Do you have an idea of what's can cause that? Thanks!
The text was updated successfully, but these errors were encountered: