am f138e3ce: am 71520a68: Merge "Handle ISE when physical volume isn\'t mounted." into jb-mr1-dev

* commit 'f138e3cec9aa6b86a0e614a39ed29f0709ebfabd':
  Handle ISE when physical volume isn't mounted.
This commit is contained in:
Jeff Sharkey
2012-10-01 10:16:35 -07:00
committed by Android Git Automerger

View File

@@ -1577,9 +1577,16 @@ class MountService extends IMountService.Stub
private void warnOnNotMounted() {
final StorageVolume primary = getPrimaryPhysicalVolume();
if (primary != null
&& Environment.MEDIA_MOUNTED.equals(getVolumeState(primary.getPath()))) {
Slog.w(TAG, "getSecureContainerList() called when storage not mounted");
if (primary != null) {
boolean mounted = false;
try {
mounted = Environment.MEDIA_MOUNTED.equals(getVolumeState(primary.getPath()));
} catch (IllegalStateException e) {
}
if (!mounted) {
Slog.w(TAG, "getSecureContainerList() called when storage not mounted");
}
}
}