java.lang.SecurityException: Unable to find app for caller android.app.ApplicationThreadProxy
用Intent傳圖片爆出瞭如下錯誤:
13:42:04.785: E/JavaBinder(497): !!! FAILED BINDER TRANSACTION !!!
11-24 13:42:04.785: E/AndroidRuntime(18419): FATAL EXCEPTION: main
11-24 13:42:04.785: E/AndroidRuntime(18419): java.lang.RuntimeException: Unable to instantiate application com.hpw.framework.MovieBaseApplication: java.lang.SecurityException: Unable to find app for caller android.app.ApplicationThreadProxy@53695198 (pid=18419) when registering receiver android.content.IIntentReceiver$Stub$Proxy@536864e0
11-24 13:42:04.785: E/AndroidRuntime(18419): at android.app.LoadedApk.makeApplication(LoadedApk.java:504)
11-24 13:42:04.785: E/AndroidRuntime(18419): at android.app.ActivityThread.handleBindApplication(ActivityThread.java:4392)
11-24 13:42:04.785: E/AndroidRuntime(18419): at android.app.ActivityThread.access$1300(ActivityThread.java:141)
11-24 13:42:04.785: E/AndroidRuntime(18419): at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1294)
11-24 13:42:04.785: E/AndroidRuntime(18419): at android.os.Handler.dispatchMessage(Handler.java:99)
11-24 13:42:04.785: E/AndroidRuntime(18419): at android.os.Looper.loop(Looper.java:137)
11-24 13:42:04.785: E/AndroidRuntime(18419): at android.app.ActivityThread.main(ActivityThread.java:5069)
11-24 13:42:04.785: E/AndroidRuntime(18419): at java.lang.reflect.Method.invokeNative(Native Method)
11-24 13:42:04.785: E/AndroidRuntime(18419): at java.lang.reflect.Method.invoke(Method.java:511)
11-24 13:42:04.785: E/AndroidRuntime(18419): at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:793)
11-24 13:42:04.785: E/AndroidRuntime(18419): at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:560)
11-24 13:42:04.785: E/AndroidRuntime(18419): at dalvik.system.NativeStart.main(Native Method)
11-24 13:42:04.785: E/AndroidRuntime(18419): Caused by: java.lang.SecurityException: Unable to find app for caller android.app.ApplicationThreadProxy@53695198 (pid=18419) when registering receiver android.content.IIntentReceiver$Stub$Proxy@536864e0
11-24 13:42:04.785: E/AndroidRuntime(18419): at android.os.Parcel.readException(Parcel.java:1425)
11-24 13:42:04.785: E/AndroidRuntime(18419): at android.os.Parcel.readException(Parcel.java:1379)
11-24 13:42:04.785: E/AndroidRuntime(18419): at android.app.ActivityManagerProxy.registerReceiver(ActivityManagerNative.java:2116)
11-24 13:42:04.785: E/AndroidRuntime(18419): at android.app.ContextImpl.registerReceiverInternal(ContextImpl.java:1335)
11-24 13:42:04.785: E/AndroidRuntime(18419): at android.app.ContextImpl.registerReceiver(ContextImpl.java:1296)
11-24 13:42:04.785: E/AndroidRuntime(18419): at android.app.ContextImpl.registerReceiver(ContextImpl.java:1290)
11-24 13:42:04.785: E/AndroidRuntime(18419): at android.app.Instrumentation.newApplication(Instrumentation.java:968)
11-24 13:42:04.785: E/AndroidRuntime(18419): at android.app.LoadedApk.makeApplication(LoadedApk.java:499)
11-24 13:42:04.785: E/AndroidRuntime(18419): ... 11 more
11-24 13:42:04.789: W/ActivityManager(497): Exception in new application when starting activity com.hpw.framework/.MovieDetailsActivity
11-24 13:42:04.789: W/ActivityManager(497): android.os.TransactionTooLargeException
11-24 13:42:04.789: W/ActivityManager(497): at android.os.BinderProxy.transact(Native Method)
11-24 13:42:04.789: W/ActivityManager(497): at android.app.ApplicationThreadProxy.scheduleLaunchActivity(ApplicationThreadNative.java:708)
11-24 13:42:04.789: W/ActivityManager(497): at com.android.server.am.ActivityStack.realStartActivityLocked(ActivityStack.java:697)
11-24 13:42:04.789: W/ActivityManager(497): at com.android.server.am.ActivityManagerService.attachApplicationLocked(ActivityManagerService.java:4270)
11-24 13:42:04.789: W/ActivityManager(497): at com.android.server.am.ActivityManagerService.attachApplication(ActivityManagerService.java:4334)
11-24 13:42:04.789: W/ActivityManager(497): at android.app.ActivityManagerNative.onTransact(ActivityManagerNative.java:386)
11-24 13:42:04.789: W/ActivityManager(497): at com.android.server.am.ActivityManagerService.onTransact(ActivityManagerService.java:1690)
11-24 13:42:04.789: W/ActivityManager(497): at android.os.Binder.execTransact(Binder.java:351)
11-24 13:42:04.789: W/ActivityManager(497): at dalvik.system.NativeStart.run(Native Method)
11-24 13:42:04.793: D/dalvikvm(18443): Late-enabling CheckJNI
11-24 13:42:04.793: E/Trace(18431): error opening trace file: No such file or directory (2)
11-24 13:42:04.793: I/ActivityManager(497): Start proc com.hpw.framework for activity com.hpw.framework/.MovieDetailsActivity: pid=18443 uid=10038 gids={50038, 3003, 1015, 1028}
後經多方查詢,終於在stackoverflow中找到答案:http://stackoverflow.com/questions/18096607/using-crop-intent-getting-java-lang-securityexception-unable-to-find-app-for-ca
原文如下:
This log means that your app is having trouble handling a communication intent. Sometimes problems like this can be cause by sending an intent with big extras. Try to reduce the dimension of the image or, and this is the best way, save your image on the sd
and put in the extras only the Uri of that image
翻譯:
意思是你在跳轉activity的過程中攜帶的extras中有圖片的Bitmap,應用盡量減少圖片的尺寸大小,應該通過儲存圖片到sd卡中或者通過uri方式傳遞圖片引數。
果然去掉了resultIntent.putExtra("bitmap", bitmap);這句後就不報錯了。
相關文章
- Unable to Find Sources for Current Linux KernelLinux
- Android:Unable to find explicit activity classAndroid
- js中的arguments,caller,callee,applyJSAPP
- Javascript - 全面理解 caller,callee,call,applyJavaScriptAPP
- Application.Caller詳細解釋APP
- 解決: selenium webdriver unable to find Mozilla geckodriverWeb
- 理解JavaScript中的arguments,callee,caller,applyJavaScriptAPP
- MySQL5.7 Unable to find a match: MySQL-community-serverMySqlUnityServer
- SSL - SSLHandshakeException: unable to find valid certification path to requested targetException
- file_get_content s()獲取https出現這個錯誤Unable to find the wrapperHTTPAPP
- Xcode指令碼自動化打包問題:xcrun: error: unable to find utility "PackageApplication", not a developer tool or in PATHXCode指令碼ErrorPackageAPPDeveloper
- 安裝或執行clone報錯 Unable to find 'kshell' in path
- Name [spring.liveBeansView.mbeanDomain] is not bound in this Context. Unable to findSpringBeanViewAIContext
- 終端報錯"xcrun: error: unable to find utility “xcodebuild”, not a developer tool orErrorXCodeUIDeveloper
- js callee與callerJS
- Find All Numbers Disappeared in an ArrayAPP
- Function.caller, arguments.caller, arguments.callee, arguments.callee.calllerFunction
- js apply/call/caller/callee/bind使用方法與區別分析JSAPP
- nancy Unable to find view engine that could render the view 無法找到檢視模板引擎NaNView
- JavaScript方法call,apply,caller,callee,bind的使用詳解及區別JavaScriptAPP
- Android Bugs—— Error:In declare-styleable FontFamilyFont, unable to find attribute android:fontAndroidError
- 448. Find All Numbers Disappeared in an ArrayAPP
- Script to find Whether patches is applied in Oracle EBSAPPOracle
- 求救--Cannot find ActionMappings or ActionFormBeans collectionAPPORMBean
- Failed ALPN negotiation: Unable to find compatible protocol&&subscriptionExpressions have not been set yetAIGoProtocolExpress
- javascript callee和caller屬性用法JavaScript
- 配置hive後設資料庫mysql時候出現 Unable to find the JDBC database jar on host : masterHive資料庫MySqlJDBCDatabaseJARAST
- cocoapods找不到第三方庫Unable to find a pod with name, author, summary, or descriptionmatching...
- the application was unable to start correctly 0xc000007bAPP
- 啟動uwsgi報錯ImportError: No module named, unable to load appImportErrorAPP
- springboot專案打包提示Unable to find a single main class from the following candidates錯誤Spring BootAI
- java.lang.SecurityException: Prohibited package name: java.pack.splitdemoJavaExceptionPackage
- LeetCode 448. Find All Numbers Disappeared in an ArrayLeetCodeAPP
- RPC: Port mapper failure - Unable to receive: errno 113 (No route to host)RPCAPPAI
- 請教:castor MappingException: Could not find the class異常ASTAPPException
- 讓服務呼叫更簡單 - Caller.HttpClientHTTPclient
- 【譯】function.caller 被認為是有害的Function
- callee與caller的區別簡單介紹