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

Commit 7ef9f61b authored by Svetoslav Ganov's avatar Svetoslav Ganov Committed by Android (Google) Code Review
Browse files

Merge "Don't dispatch Uris with appended user handle" into nyc-dev

parents b1f3404f 3138a993
Loading
Loading
Loading
Loading
+2 −11
Original line number Diff line number Diff line
@@ -394,18 +394,9 @@ public final class ContentService extends IContentService.Stub {
            for (int i=0; i<numCalls; i++) {
                ObserverCall oc = calls.get(i);
                try {
                    // If the uri does not belong to the same user as the observer: we must add
                    // the userId to the uri. Otherewise the observer would think the uri belongs
                    // to his user.
                    final Uri tempUri;
                    if (oc.mObserverUserId != userHandle) {
                        tempUri = ContentProvider.maybeAddUserId(uri, userHandle);
                    } else {
                        tempUri = uri;
                    }
                    oc.mObserver.onChange(oc.mSelfChange, tempUri, userHandle);
                    oc.mObserver.onChange(oc.mSelfChange, uri, userHandle);
                    if (DEBUG) Slog.d(TAG, "Notified " + oc.mObserver + " of " + "update at "
                            + tempUri);
                            + uri);
                } catch (RemoteException ex) {
                    synchronized (mRootNode) {
                        Log.w(TAG, "Found dead observer, removing");