[PackageInstaller] catch yet another exception

In certain corner cases ContentResolver might throw an
IllegalArgumentException. The caller is expected to catch such exception
and handle it gracefully.

BUG: 240380933
Test: builds
Change-Id: I14cae1d54d65957a418551cea5db5e1bcab14acb
This commit is contained in:
Songchun Fan
2022-08-16 11:39:02 -07:00
parent 723ce1431b
commit f982d7e77a

View File

@@ -189,7 +189,8 @@ public class InstallStaging extends AlertActivity {
out.write(buffer, 0, bytesRead);
}
}
} catch (IOException | SecurityException | IllegalStateException e) {
} catch (IOException | SecurityException | IllegalStateException
| IllegalArgumentException e) {
Log.w(LOG_TAG, "Error staging apk from content URI", e);
return false;
}