Error: JNI ERROR (app bug): accessed stale global reference

后端 未结 4 1682
难免孤独
难免孤独 2020-12-16 14:39

I am getting this error JNI ERROR (app bug): accessed stale global reference When I run my app in Android OS v4, But when I run the same application in Andr

4条回答
  •  忘掉有多难
    2020-12-16 15:05

    This applies to kotlin:

    To add to what @krys has already mentioned, make sure that signatures on Kotlin side match exactly what you have in the JNI code. Even a simple Void (avoid explicit Void at the end of function signatures that return void on the JNI side) signature at the end of kotlin reference may fail and would make your debugging extremely frustrating.

提交回复
热议问题