Merge "Avoid NPE when installing app update." into jb-mr1-dev
This commit is contained in:
@@ -568,6 +568,7 @@ public class InstalledAppDetails extends Fragment
|
||||
}
|
||||
}
|
||||
mAppEntry = mState.getEntry(packageName);
|
||||
if (mAppEntry != null) {
|
||||
// Get application info again to refresh changed properties of application
|
||||
try {
|
||||
mPackageInfo = mPm.getPackageInfo(mAppEntry.info.packageName,
|
||||
@@ -577,6 +578,10 @@ public class InstalledAppDetails extends Fragment
|
||||
} catch (NameNotFoundException e) {
|
||||
Log.e(TAG, "Exception when retrieving package:" + mAppEntry.info.packageName, e);
|
||||
}
|
||||
} else {
|
||||
Log.w(TAG, "Missing AppEntry; maybe reinstalling?");
|
||||
mPackageInfo = null;
|
||||
}
|
||||
|
||||
return packageName;
|
||||
}
|
||||
|
Reference in New Issue
Block a user