From 702d860381925ff699af701b6661d828aab2a422 Mon Sep 17 00:00:00 2001 From: Devin Moore Date: Wed, 14 Dec 2022 19:05:02 +0000 Subject: [PATCH] Add comment for thrown exception in waitForDeclaredService Test: none Bug: none Change-Id: Ic62297e86fe961a643b1e180334a3a309e0f7b28 --- core/java/android/os/ServiceManager.java | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/core/java/android/os/ServiceManager.java b/core/java/android/os/ServiceManager.java index 394927e171672..b210c4644d7d6 100644 --- a/core/java/android/os/ServiceManager.java +++ b/core/java/android/os/ServiceManager.java @@ -292,8 +292,10 @@ public final class ServiceManager { * If the service is not running, servicemanager will attempt to start it, and this function * will wait for it to be ready. * - * @return {@code null} if the service is not declared in the manifest, or if there are - * permission problems, or if there are fatal errors. + * @throws SecurityException if the process does not have the permissions to check + * isDeclared() for the service. + * @return {@code null} if the service is not declared in the manifest, or if there + * are fatal errors. * @hide */ @SystemApi(client = SystemApi.Client.MODULE_LIBRARIES)