Merge "use public constructor for SmsCbLocation"
diff --git a/AndroidManifest.xml b/AndroidManifest.xml
index 4dc0b97..e075727 100644
--- a/AndroidManifest.xml
+++ b/AndroidManifest.xml
@@ -48,6 +48,7 @@
android:authorities="cellbroadcasts"
android:exported="true"
android:singleUser="true"
+ android:readPermission="android.permission.READ_CELL_BROADCASTS"
android:multiprocess="false" />
</application>
</manifest>
diff --git a/src/com/android/cellbroadcastservice/CellBroadcastProvider.java b/src/com/android/cellbroadcastservice/CellBroadcastProvider.java
index 1369b52..34fbf66 100644
--- a/src/com/android/cellbroadcastservice/CellBroadcastProvider.java
+++ b/src/com/android/cellbroadcastservice/CellBroadcastProvider.java
@@ -16,7 +16,6 @@
package com.android.cellbroadcastservice;
-import android.app.AppOpsManager;
import android.content.ContentProvider;
import android.content.ContentUris;
import android.content.ContentValues;
@@ -153,7 +152,6 @@
public boolean onCreate() {
mDbHelper = new CellBroadcastDatabaseHelper(getContext());
mPermissionChecker = new CellBroadcastPermissionChecker();
- setAppOps(AppOpsManager.OP_READ_CELL_BROADCASTS, AppOpsManager.OP_NONE);
return true;
}
diff --git a/tests/AndroidManifest.xml b/tests/AndroidManifest.xml
index 7403d26..fd60e45 100644
--- a/tests/AndroidManifest.xml
+++ b/tests/AndroidManifest.xml
@@ -17,6 +17,8 @@
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
package="com.android.cellbroadcastservice.tests">
+ <uses-permission android:name="android.permission.READ_CELL_BROADCASTS" />
+
<application>
<uses-library android:name="android.test.runner" />
</application>