[iOS] EXC_BAD_ACCESS
See original GitHub issueMy app crash every time I try to do this and only this query to the realm database. It happens only in iOS and in Debug Mode. Release mode works as expected.
PS: To clarify when I say debug Mode, I don’t mean the Debug Mode “Debug JS Remotely”, what I mean is Application Scheme Build Configuration in Debug.
Query:
realm.objects('playersInfo').filtered(queryString + " OR " + queryString2, [200, 500], this.props.onLoan, userInfo.SystemVisible).sorted('updated', true);
App Crash error:
Error: com.facebook.react.JavaScript (10): EXC_BAD_ACCESS (code=2, address=0x7000080b1f88)
(lldb) register read General Purpose Registers: rbx = 0x0000000128600000 rbp = 0x00007000014edf10 rsp = 0x00007000014ed620 r12 = 0x0000000000000004 r13 = 0x00007000014ee210 r14 = 0x00007000014ee068 r15 = 0x0000000000000004 rip = 0x000000010c0d23c9 MyApplicationName`OpaqueJSValue* realm::js::ResultsClassrealm::jsc::Types::create_filtered<realm::js::Resultsrealm::jsc::Types >(OpaqueJSContext const*, realm::js::Resultsrealm::jsc::Types const&, realm::js::Argumentsrealm::jsc::Types) + 505 at js_results.hpp:190 13 registers were unavailable.
Goals
To retrieve the results.
Expected Results
To retrieve the results.
Actual Results
App crash.
Error: com.facebook.react.JavaScript (10): EXC_BAD_ACCESS (code=2, address=0x7000080b1f88)
Steps to Reproduce
Maybe have a query string really really big. Still trying to reproduce.
Version of Realm and Tooling
“realm”: “^2.7.2” “react-native”: “0.52.1”, Client OS & Version: High Sierra
Issue Analytics
- State:
- Created 5 years ago
- Comments:21 (11 by maintainers)
Top GitHub Comments
We have just re-implemented the query parser and the new parser should not suffer from this problem.
@ironage Thanks for the response =D But unfortunately, I’m already doing that xD. And the part that breaks the code is really “queryString2” here there are only “OR”. I already found a way to work around this but it’s such a nasty way that I’m trying to see if any other idea comes to mind xD @kneth @ironage thank you very much, hope to see this fix in the future and keep up the awesome work =D 🚀 🌕 🌕