Skip to content
This repository has been archived by the owner on Sep 6, 2019. It is now read-only.

Commit

Permalink
Updated requirements to prevent warning
Browse files Browse the repository at this point in the history
Refs #1757
  • Loading branch information
M66B committed Feb 15, 2015
1 parent b83a9de commit f98f514
Showing 1 changed file with 11 additions and 10 deletions.
21 changes: 11 additions & 10 deletions src/biz/bokhorst/xprivacy/Requirements.java
Original file line number Diff line number Diff line change
Expand Up @@ -150,20 +150,21 @@ public void onClick(DialogInterface dialog, int which) {
reportClass(InterfaceAddress.class, context);

// Check package manager service
try {
Class<?> clazz = Class.forName("com.android.server.pm.PackageManagerService", false, null);
if (Build.VERSION.SDK_INT < Build.VERSION_CODES.LOLLIPOP)
try {
Class<?> clazz = Class.forName("com.android.server.pm.PackageManagerService", false, null);
try {
clazz.getDeclaredMethod("getPackageUid", String.class, int.class);
} catch (NoSuchMethodException ignored) {
clazz.getDeclaredMethod("getPackageUid", String.class);
try {
clazz.getDeclaredMethod("getPackageUid", String.class, int.class);
} catch (NoSuchMethodException ignored) {
clazz.getDeclaredMethod("getPackageUid", String.class);
}
} catch (NoSuchMethodException ex) {
reportClass(clazz, context);
}
} catch (NoSuchMethodException ex) {
reportClass(clazz, context);
} catch (ClassNotFoundException ex) {
sendSupportInfo(ex.toString(), context);
}
} catch (ClassNotFoundException ex) {
sendSupportInfo(ex.toString(), context);
}

// Check GPS status
if (!checkField(GpsStatus.class, "mSatellites"))
Expand Down

0 comments on commit f98f514

Please sign in to comment.