Rethrow setMediaButtonBroadcastReceiver exceptions

setMediaButtonBroadcastReceiver signals invalid arguments with
exceptions, so remote exceptions are valid and should be rethrown from
system server.

Test: atest CtsMediaBetterTogetherTestCases
Bug: 205124386
Change-Id: I6cb66d8336735f9c32d30d7d49ff28a2797bec60
This commit is contained in:
Iván Budnik
2023-06-23 14:42:07 +00:00
parent d307ab0cf2
commit ca2a37e7d8

View File

@@ -315,7 +315,7 @@ public final class MediaSession {
}
mBinder.setMediaButtonBroadcastReceiver(broadcastReceiver);
} catch (RemoteException e) {
Log.wtf(TAG, "Failure in setMediaButtonBroadcastReceiver.", e);
e.rethrowFromSystemServer();
}
}