Loading services/core/java/com/android/server/am/ProcessErrorStateRecord.java +4 −5 Original line number Original line Diff line number Diff line Loading @@ -303,17 +303,17 @@ class ProcessErrorStateRecord { float loadingProgress = 1; float loadingProgress = 1; IncrementalMetrics incrementalMetrics = null; IncrementalMetrics incrementalMetrics = null; final PackageManagerInternal packageManagerInternal = mService.getPackageManagerInternal(); final PackageManagerInternal packageManagerInternal = mService.getPackageManagerInternal(); if (aInfo != null && aInfo.packageName != null) { if (mApp.info != null && mApp.info.packageName != null) { IncrementalStatesInfo incrementalStatesInfo = IncrementalStatesInfo incrementalStatesInfo = packageManagerInternal.getIncrementalStatesInfo( packageManagerInternal.getIncrementalStatesInfo( aInfo.packageName, mApp.uid, mApp.userId); mApp.info.packageName, mApp.uid, mApp.userId); if (incrementalStatesInfo != null) { if (incrementalStatesInfo != null) { loadingProgress = incrementalStatesInfo.getProgress(); loadingProgress = incrementalStatesInfo.getProgress(); } } final String codePath = aInfo.getCodePath(); final String codePath = mApp.info.getCodePath(); if (IncrementalManager.isIncrementalPath(codePath)) { if (IncrementalManager.isIncrementalPath(codePath)) { // Report in the main log that the incremental package is still loading // Report in the main log that the incremental package is still loading Slog.e(TAG, "App crashed on incremental package " + aInfo.packageName Slog.e(TAG, "App ANR on incremental package " + mApp.info.packageName + " which is " + ((int) (loadingProgress * 100)) + "% loaded."); + " which is " + ((int) (loadingProgress * 100)) + "% loaded."); final IBinder incrementalService = ServiceManager.getService( final IBinder incrementalService = ServiceManager.getService( Context.INCREMENTAL_SERVICE); Context.INCREMENTAL_SERVICE); Loading Loading @@ -418,7 +418,6 @@ class ProcessErrorStateRecord { mService.mProcessList.mAppExitInfoTracker.scheduleLogAnrTrace( mService.mProcessList.mAppExitInfoTracker.scheduleLogAnrTrace( pid, mApp.uid, mApp.getPackageList(), tracesFile, offsets[0], offsets[1]); pid, mApp.uid, mApp.getPackageList(), tracesFile, offsets[0], offsets[1]); } } FrameworkStatsLog.write(FrameworkStatsLog.ANR_OCCURRED, mApp.uid, mApp.processName, FrameworkStatsLog.write(FrameworkStatsLog.ANR_OCCURRED, mApp.uid, mApp.processName, activityShortComponentName == null ? "unknown" : activityShortComponentName, activityShortComponentName == null ? "unknown" : activityShortComponentName, annotation, annotation, Loading Loading
services/core/java/com/android/server/am/ProcessErrorStateRecord.java +4 −5 Original line number Original line Diff line number Diff line Loading @@ -303,17 +303,17 @@ class ProcessErrorStateRecord { float loadingProgress = 1; float loadingProgress = 1; IncrementalMetrics incrementalMetrics = null; IncrementalMetrics incrementalMetrics = null; final PackageManagerInternal packageManagerInternal = mService.getPackageManagerInternal(); final PackageManagerInternal packageManagerInternal = mService.getPackageManagerInternal(); if (aInfo != null && aInfo.packageName != null) { if (mApp.info != null && mApp.info.packageName != null) { IncrementalStatesInfo incrementalStatesInfo = IncrementalStatesInfo incrementalStatesInfo = packageManagerInternal.getIncrementalStatesInfo( packageManagerInternal.getIncrementalStatesInfo( aInfo.packageName, mApp.uid, mApp.userId); mApp.info.packageName, mApp.uid, mApp.userId); if (incrementalStatesInfo != null) { if (incrementalStatesInfo != null) { loadingProgress = incrementalStatesInfo.getProgress(); loadingProgress = incrementalStatesInfo.getProgress(); } } final String codePath = aInfo.getCodePath(); final String codePath = mApp.info.getCodePath(); if (IncrementalManager.isIncrementalPath(codePath)) { if (IncrementalManager.isIncrementalPath(codePath)) { // Report in the main log that the incremental package is still loading // Report in the main log that the incremental package is still loading Slog.e(TAG, "App crashed on incremental package " + aInfo.packageName Slog.e(TAG, "App ANR on incremental package " + mApp.info.packageName + " which is " + ((int) (loadingProgress * 100)) + "% loaded."); + " which is " + ((int) (loadingProgress * 100)) + "% loaded."); final IBinder incrementalService = ServiceManager.getService( final IBinder incrementalService = ServiceManager.getService( Context.INCREMENTAL_SERVICE); Context.INCREMENTAL_SERVICE); Loading Loading @@ -418,7 +418,6 @@ class ProcessErrorStateRecord { mService.mProcessList.mAppExitInfoTracker.scheduleLogAnrTrace( mService.mProcessList.mAppExitInfoTracker.scheduleLogAnrTrace( pid, mApp.uid, mApp.getPackageList(), tracesFile, offsets[0], offsets[1]); pid, mApp.uid, mApp.getPackageList(), tracesFile, offsets[0], offsets[1]); } } FrameworkStatsLog.write(FrameworkStatsLog.ANR_OCCURRED, mApp.uid, mApp.processName, FrameworkStatsLog.write(FrameworkStatsLog.ANR_OCCURRED, mApp.uid, mApp.processName, activityShortComponentName == null ? "unknown" : activityShortComponentName, activityShortComponentName == null ? "unknown" : activityShortComponentName, annotation, annotation, Loading