Fix #38218977 : NPE restoring widget mappings
Remember that we might not be able to resolve historical widget provider references, so don't access them unchecked. Test: manual Change-Id: I01c6c68461b6d15aa8fee402a4bfb0f21bf1ddbb
This commit is contained in:
@@ -4365,7 +4365,7 @@ class AppWidgetServiceImpl extends IAppWidgetService.Stub implements WidgetBacku
|
||||
}
|
||||
addWidgetLocked(id);
|
||||
}
|
||||
if (id.provider.info != null) {
|
||||
if (id.provider != null && id.provider.info != null) {
|
||||
stashProviderRestoreUpdateLocked(id.provider,
|
||||
restoredId, id.appWidgetId);
|
||||
} else {
|
||||
|
||||
Reference in New Issue
Block a user