Samsum with Android 5 - Native crash at /system/framework/arm/boot.oat

I was referring to the first crash. While we do try and trap that with a Lua error, that doesn’t mean that certain device’s forks of Android don’t have issues that’s causing the segment violation. This seems to be limited to a few certain device combinations.

Rob

Any progress with either the first or the second crashes?

Both are reproducing quite a bit, and both only to Samsung devices running Android 5…

We really need a test case that causes the problem and a bug report filed to get Engineering a chance to find this. Since this is going to be hard to reproduce and we had a similar report that’s related to removing an object that’s already been removed, I would suggest  that you check your code to see there are any places where you might be double removing an object. :removeSelf() calls that don’t test to see if the object exists before removing them.

These kinds of problems are tough to narrow down. Perhaps you could ask around and see if a developer has the same device that you’re seeing these crashes on and see if they can get a console log of the crash that might clue us in to where the problem is occurring.

Rob

I added a pcall around the creation of the text view that is causing the crash.

It still crashes on some Samsung devices with Android 5, but most of the crashes are caught

In the detected crashes, I see the following stack traces

java.lang.IllegalStateException Java Stack Trace: java.util.concurrent.ConcurrentLinkedQueue$Itr.remove(ConcurrentLinkedQueue.java:710) java.util.concurrent.ConcurrentLinkedDeque$DescendingItr.startNode(ConcurrentLinkedDeque.java:1355) java.util.concurrent.ConcurrentLinkedDeque$AbstractItr.advance(ConcurrentLinkedDeque.java:1310) java.util.concurrent.ConcurrentLinkedDeque$AbstractItr.\<init\>(ConcurrentLinkedDeque.java:1300) java.util.concurrent.ConcurrentLinkedDeque$DescendingItr.\<init\>(ConcurrentLinkedDeque.java:1354) java.util.concurrent.ConcurrentLinkedDeque$DescendingItr.\<init\>(ConcurrentLinkedDeque.java:1354) java.util.concurrent.ConcurrentLinkedDeque.descendingIterator(ConcurrentLinkedDeque.java:1273) android.text.TextUtils.getChars(TextUtils.java:85) android.text.TextUtils.indexOf(TextUtils.java:118) android.text.StaticLayout.generate(StaticLayout.java:184) android.text.StaticLayout.\<init\>(StaticLayout.java:141) android.text.StaticLayout.\<init\>(StaticLayout.java:92) android.text.StaticLayout.\<init\>(StaticLayout.java:70) android.text.StaticLayout.\<init\>(StaticLayout.java:50) com.ansca.corona.graphics.TextRenderer.createBitmap(TextRenderer.java:253) com.ansca.corona.NativeToJavaBridge.callRenderText(NativeToJavaBridge.java:1505) com.naef.jnlua.LuaState.lua\_pcall(Native Method) com.naef.jnlua.LuaState.call(Unknown Source) com.ansca.corona.CoronaLua.dispatchEvent(CoronaLua.java:138) network.NetworkRequest$LuaCallback$1.executeUsing(NetworkRequest.java:610) com.ansca.corona.CoronaRuntimeTaskDispatcher$TaskEvent.Send(CoronaRuntimeTaskDispatcher.java:170) com.ansca.corona.events.EventManager.sendEvents(EventManager.java:91) com.ansca.corona.Controller.updateRuntimeState(Controller.java:308) com.ansca.corona.graphics.opengl.CoronaGLSurfaceView$CoronaRenderer.onDrawFrame(CoronaGLSurfaceView.java:421) com.ansca.corona.graphics.opengl.GLSurfaceView$GLThread.guardedRun(GLSurfaceView.java:1623) com.ansca.corona.graphics.opengl.GLSurfaceView$GLThread.run(GLSurfaceView.java:1378)

and 

java.lang.AbstractMethodError: abstract method \"int java.sql.Savepoint.getSavepointId()\" Java Stack Trace: android.text.StaticLayout.\<init\>(StaticLayout.java:51) com.ansca.corona.graphics.TextRenderer.createBitmap(TextRenderer.java:253) com.ansca.corona.NativeToJavaBridge.callRenderText(NativeToJavaBridge.java:1505) com.naef.jnlua.LuaState.lua\_pcall(Native Method)\n\tcom.naef.jnlua.LuaState.call(Unknown Source) com.ansca.corona.CoronaLua.dispatchEvent(CoronaLua.java:138) network.NetworkRequest$LuaCallback$1.executeUsing(NetworkRequest.java:610) com.ansca.corona.CoronaRuntimeTaskDispatcher$TaskEvent.Send(CoronaRuntimeTaskDispatcher.java:170) com.ansca.corona.events.EventManager.sendEvents(EventManager.java:91) com.ansca.corona.Controller.updateRuntimeState(Controller.java:308) com.ansca.corona.graphics.opengl.CoronaGLSurfaceView$CoronaRenderer.onDrawFrame(CoronaGLSurfaceView.java:421) com.ansca.corona.graphics.opengl.GLSurfaceView$GLThread.guardedRun(GLSurfaceView.java:1623) com.ansca.corona.graphics.opengl.GLSurfaceView$GLThread.run(GLSurfaceView.java:1378)

and all of these errors are triggered by the same call to:

local textOptions = { &nbsp; &nbsp; text = messageVariable, &nbsp; &nbsp; ... } display.newText(textOptions)

To remind you, this crash (detected or not) only occurs on Samsung devices running android 5.X.

What could possibly trigger these errors when creating a new text object?

It has to be something with the message itself that is being shown, but what about it?

A long message? a certain character? Why would one message be ok and another not?

Any help would be greatly appreciated… 

We certainly would like to see more code. The complete constructor would be helpful.  What would be best is a simple test case that causes the crash on that specific platform where our Engineers could see the crash happen… i.e. an bug report

Rob