我已經在生產中Xamarin的Android應用程序,我看到不少跟隨崩潰在谷歌Play開發者控制檯報告:什麼時候涉及應用程序啓動的儀器?
java.lang.UnsatisfiedLinkError: Native method not found:
mono.android.Runtime.register:(Ljava/lang/String;Ljava/lang/Class;Ljava/lang/String;)V
at mono.android.Runtime.register(Native Method)
at speedcamapp.SpeedcamApplication.onCreate(SpeedcamApplication.java:18)
at
android.app.Instrumentation.callApplicationOnCreate(Instrumentation.java:1008)
at android.app.ActivityThread.handleBindApplication(ActivityThread.java:4506)
at android.app.ActivityThread.access$1500(ActivityThread.java:144)
at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1306)
at android.os.Handler.dispatchMessage(Handler.java:106)
at android.os.Looper.loop(Looper.java:136)
at android.app.ActivityThread.main(ActivityThread.java:5196)
at java.lang.reflect.Method.invokeNative(Native Method)
at java.lang.reflect.Method.invoke(Method.java:515)
at
com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:786)
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:602)
at dalvik.system.NativeStart.main(Native Method)
因爲這似乎是Xamarin的bug,I asked them and I was told問題是這一行:
at android.app.Instrumentation.callApplicationOnCreate(Instrumentation.java:1008)
這是不正常的應用程序啓動儀器,它意味着有人正在「擺弄」我的應用程序。
但我可以看到許多這樣的錯誤,從許多不同的設備,有的網友甚至留下留言「它停止工作」與他們的崩潰報告...
我試着用搜索引擎「android.app.Instrumentation .callApplicationOnCreate「,我在日誌中發現了這條線的許多應用程序日誌。
所以我的問題是,那「android.app.Instrumentation.callApplicationOnCreate」真的是什麼意思? 這種情況何時會發生在普通用戶身上?
你是對的;總是調用Instrumentation.callApplicationOnCreate()。這裏令人困惑的是,afaict,'System.loadLibrary(「monodroid」)'*應該*作爲'installContentProviders()'的一部分被調用,它在*'callApplicationOnCreate()'之前*,但是沒有找到該符號。爲什麼沒有找到符號? – jonp 2015-03-20 21:56:45