Don't log stacks for exceptions recieved from binder

The stacks for these exceptions are not helpful, as they just show
binder internals and spew noise into the logs.

Test: Manual
Change-Id: Ib3aae63b1f31a0ebbcbeaf7519bcd65b6903ab2c
This commit is contained in:
Seth Moore
2023-04-04 14:01:42 -07:00
parent db93b81cf5
commit 0f771dcecc

View File

@@ -70,12 +70,14 @@ final class RemoteProvisioningRegistration extends IRegistration.Stub {
Log.i(TAG, "Operation cancelled for client " + mCallback.hashCode());
wrapCallback(mCallback::onCancel);
} else if (e instanceof RkpProxyException) {
Log.e(TAG, "RKP error fetching key for client " + mCallback.hashCode(), e);
Log.e(TAG, "RKP error fetching key for client " + mCallback.hashCode() + ": "
+ e.getMessage());
RkpProxyException rkpException = (RkpProxyException) e;
wrapCallback(() -> mCallback.onError(toGetKeyError(rkpException),
e.getMessage()));
} else {
Log.e(TAG, "Error fetching key for client " + mCallback.hashCode(), e);
Log.e(TAG, "Unknown error fetching key for client " + mCallback.hashCode() + ": "
+ e.getMessage());
wrapCallback(() -> mCallback.onError(IGetKeyCallback.ErrorCode.ERROR_UNKNOWN,
e.getMessage()));
}