这是包含错误的日志。
E/AndroidRuntime: FATAL EXCEPTION: Thread-202
Process: org.cade.codigos, PID: 2798
java.lang.SecurityException: Permission Denial: opening provider com.android.browser.provider.BrowserProvider2 from ProcessRecord{f90b843 2798:org.cade.codigos/u0a57} (pid=2798, uid=10057)
requires com.android.browser.permission.READ_HISTORY_BOOKMARKS
or com.android.browser.permission.WRITE_HISTORY_BOOKMARKS
at android.os.Parcel.readException(Parcel.java:1599)
at android.os.Parcel.readException(Parcel.java:1552)
at android.app.ActivityManagerProxy.getContentProvider(ActivityManagerNative.java:3550)
at android.app.ActivityThread.acquireProvider(ActivityThread.java:4778)
at android.app.ContextImpl$ApplicationContentResolver.acquireUnstableProvider(ContextImpl.java:2018)
at android.content.ContentResolver.acquireUnstableProvider(ContentResolver.java:1468)
at android.content.ContentResolver.query(ContentResolver.java:475)
at android.content.ContentResolver.query(ContentResolver.java:434)
at org.cade.codigos.providers.BookmarksProviderWrapper.updateHistory(BookmarksProviderWrapper.java:370)
at org.cade.codigos.ui.runnables.HistoryUpdater.run(HistoryUpdater.java:53)
at java.lang.Thread.run(Thread.java:818)
值得注意的是,在尝试使用Nexus 5(Android 6.0,Api 23)时,Nexus S Api 22棒棒糖正在运行。
这是整个Manifest,目前我只使用.codigos.ui.activities.RequestDataForm和.codigos.ui.activities.MainActivity
<?xml version="1.0" encoding="utf-8"?>
<!--
CADE Browser for Android
Copyright (C) 2014
-->
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
package="org.cade"
android:installLocation="auto"
android:versionCode="13"
android:versionName="1">
android:versionName="CADE Codigos" >
<uses-sdk android:minSdkVersion="16"
android:targetSdkVersion="16"
/>
<uses-permission android:name="android.permission.INTERNET" />
<uses-permission android:name="com.android.browser.permission.READ_HISTORY_BOOKMARKS" />
<uses-permission android:name="com.android.browser.permission.WRITE_HISTORY_BOOKMARKS" />
<uses-permission android:name="android.permission.WRITE_EXTERNAL_STORAGE" />
<uses-permission android:name="android.permission.READ_PHONE_STATE" />
<uses-permission android:name="android.permission.READ_EXTERNAL_STORAGE"/>
<uses-permission android:name="android.permission.ACCESS_NETWORK_STATE" />
<uses-permission android:name="android.permission.ACCESS_WIFI_STATE" />
<uses-permission android:name="android.permission.WAKE_LOCK" />
<uses-permission android:name="android.permission.VIBRATE" />
<uses-permission android:name="android.permission.GET_ACCOUNTS" />
<uses-permission android:name="com.google.android.c2dm.permission.RECEIVE" />
<permission android:protectionLevel="signature"
android:name="com.parse.starter.permission.C2D_MESSAGE" />
<uses-permission android:name="org.cade.codigos.permission.C2D_MESSAGE" />
<uses-feature
android:name="android.hardware.touchscreen"
android:required="true" />
<application
android:name=".codigos.ui.activities.Application"
android:icon="@drawable/ic_launcher"
android:label="CADE Códigos" >
<!-- android:debuggable="false" -->
<activity
android:name=".codigos.ui.activities.RequestDataForm"
android:configChanges="keyboardHidden|orientation"
android:label="CADE Códigos">
</activity>
<activity
android:name=".codigos.ui.activities.AboutActivity"
android:label="@string/AboutActivity.Title"
android:theme="@android:style/Theme.Dialog" />
<activity
android:name=".codigos.ui.activities.EditBookmarkActivity"
android:label="@string/EditBookmarkActivity.Title"
android:theme="@android:style/Theme.Dialog" />
<activity android:name=".codigos.ui.activities.BookmarksListActivity" />
<activity android:name=".codigos.ui.activities.HistoryListActivity" />
<activity android:name=".codigos.ui.activities.DownloadsListActivity" />
<activity android:name=".codigos.ui.activities.AdBlockerWhiteListActivity" />
<activity
android:name=".codigos.ui.activities.BookmarksHistoryActivity"
android:configChanges="keyboardHidden|orientation" />
<activity
android:name=".codigos.ui.activities.ChangelogActivity"
android:label="@string/ChangelogActivity.Title"
android:theme="@android:style/Theme.Dialog" />
<activity android:name=".codigos.ui.activities.preferences.PreferencesActivity" />
<activity
android:name=".codigos.ui.activities.preferences.HomepagePreferenceActivity"
android:label="@string/HomepagePreferenceActivity.Title"
android:theme="@android:style/Theme.Dialog" />
<activity
android:name=".codigos.ui.activities.preferences.SearchUrlPreferenceActivity"
android:label="@string/SearchUrlPreferenceActivity.Title"
android:theme="@android:style/Theme.Dialog" />
<activity
android:name=".codigos.ui.activities.preferences.UserAgentPreferenceActivity"
android:label="@string/UserAgentPreferenceActivity.Title"
android:theme="@android:style/Theme.Dialog" />
<activity android:name=".codigos.ui.activities.MobileViewListActivity" />
<activity android:name=".codigos.ui.activities.WeaveBookmarksListActivity" />
<activity android:name=".codigos.ui.activities.preferences.WeavePreferencesActivity" />
<activity
android:name=".codigos.ui.activities.preferences.WeaveServerPreferenceActivity"
android:label="@string/WeaveServerPreferenceActivity.Title"
android:theme="@android:style/Theme.Dialog" />
<provider
android:name=".codigos.providers.ZircoBookmarksContentProvider"
android:authorities="org.cade.codigos.providers.zircobookmarkscontentprovider" />
<provider
android:name=".codigos.providers.WeaveContentProvider"
android:authorities="org.cade.codigos.providers.weavecontentprovider" />
<receiver android:name=".codigos.utils.ProxyChangeReceiver" >
<intent-filter>
<action android:name="android.intent.action.PROXY_CHANGE" />
</intent-filter>
</receiver>
<activity android:name=".codigos.ui.activities.Splashscreen"
android:label="CADE App">
<intent-filter>
<action android:name="android.intent.action.MAIN" />
<category android:name="android.intent.category.LAUNCHER" />
</intent-filter>
</activity>
<activity
android:name=".codigos.ui.activities.MainActivity"
android:configChanges="orientation|keyboardHidden"
android:label="CADE Codigos" >
<intent-filter>
<action android:name="android.intent.action.VIEW" />
<category android:name="android.intent.category.DEFAULT" />
<data android:scheme="http" />
<data android:scheme="https" />
</intent-filter>
<intent-filter>
<action android:name="android.intent.action.MAIN" />
<category android:name="android.intent.category.DEFAULT" />
</intent-filter>
</activity>
<service android:name="com.parse.PushService" />
<receiver
android:name="org.cade.codigos.ui.activities.Receiver"
android:exported="false" >
<intent-filter>
<action android:name="com.parse.push.intent.RECEIVE" />
<action android:name="com.parse.push.intent.DELETE" />
<action android:name="com.parse.push.intent.OPEN" />
</intent-filter>
</receiver>
<receiver android:name="com.parse.GcmBroadcastReceiver"
android:permission="com.google.android.c2dm.permission.SEND">
<intent-filter>
<action android:name="com.google.android.c2dm.intent.RECEIVE" />
<action android:name="com.google.android.c2dm.intent.REGISTRATION" />
<category android:name="org.cade.codigos" />
</intent-filter>
</receiver>
</application>
</manifest>