summaryrefslogtreecommitdiffstats
path: root/core/java/android/content/ContentService.java
diff options
context:
space:
mode:
Diffstat (limited to 'core/java/android/content/ContentService.java')
-rw-r--r--core/java/android/content/ContentService.java5
1 files changed, 3 insertions, 2 deletions
diff --git a/core/java/android/content/ContentService.java b/core/java/android/content/ContentService.java
index 0f6488a..4512e82 100644
--- a/core/java/android/content/ContentService.java
+++ b/core/java/android/content/ContentService.java
@@ -345,10 +345,11 @@ public final class ContentService extends IContentService.Stub {
public SyncAdapterType[] getSyncAdapterTypes() {
// This makes it so that future permission checks will be in the context of this
// process rather than the caller's process. We will restore this before returning.
- long identityToken = clearCallingIdentity();
+ final int userId = UserHandle.getCallingUserId();
+ final long identityToken = clearCallingIdentity();
try {
SyncManager syncManager = getSyncManager();
- return syncManager.getSyncAdapterTypes();
+ return syncManager.getSyncAdapterTypes(userId);
} finally {
restoreCallingIdentity(identityToken);
}