Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 3f9ce4c2 authored by Jeff Sharkey's avatar Jeff Sharkey Committed by Android (Google) Code Review
Browse files

Merge "Verify AppWidget ownership during update." into ics-mr1

parents 76b06759 933decaa
Loading
Loading
Loading
Loading
+4 −1
Original line number Diff line number Diff line
@@ -751,13 +751,16 @@ class AppWidgetService extends IAppWidgetService.Stub
                return;
            }
            ArrayList<AppWidgetId> instances = p.instances;
            final int callingUid = getCallingUid();
            final int N = instances.size();
            for (int i=0; i<N; i++) {
                AppWidgetId id = instances.get(i);
                if (canAccessAppWidgetId(id, callingUid)) {
                    updateAppWidgetInstanceLocked(id, views);
                }
            }
        }
    }

    void updateAppWidgetInstanceLocked(AppWidgetId id, RemoteViews views) {
        updateAppWidgetInstanceLocked(id, views, false);