SystemInstaller: don't try to remove system apps without updates
Šī revīzija ir iekļauta:
vecāks
8d5c7abe89
revīzija
ba54e8b798
@ -193,7 +193,16 @@ public class SystemInstaller extends Installer {
|
|||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
final boolean isSystem = ((appInfo.flags & ApplicationInfo.FLAG_SYSTEM) != 0);
|
||||||
final boolean isUpdate = ((appInfo.flags & ApplicationInfo.FLAG_UPDATED_SYSTEM_APP) != 0);
|
final boolean isUpdate = ((appInfo.flags & ApplicationInfo.FLAG_UPDATED_SYSTEM_APP) != 0);
|
||||||
|
|
||||||
|
if (isSystem && !isUpdate) {
|
||||||
|
// Cannot remove system apps unless we're uninstalling updates
|
||||||
|
mCallback.onError(InstallerCallback.OPERATION_DELETE,
|
||||||
|
InstallerCallback.ERROR_CODE_OTHER);
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
int messageId;
|
int messageId;
|
||||||
if (isUpdate) {
|
if (isUpdate) {
|
||||||
messageId = R.string.uninstall_update_confirm;
|
messageId = R.string.uninstall_update_confirm;
|
||||||
|
|||||||
Notiek ielāde…
x
Atsaukties uz šo jaunā problēmā
Block a user