summaryrefslogtreecommitdiff
path: root/tests/DynamicCodeLoggerIntegrationTests/src/cpp/test_executable.cpp
diff options
context:
space:
mode:
authorLee Shombert <shombert@google.com>2020-04-03 14:00:40 -0700
committerLee Shombert <shombert@google.com>2020-04-06 18:07:33 -0700
commit81a3e1c578b5618bf02968a9b4402e70592b7b9b (patch)
treee5e53b3e1b9b2f6f2c636a9af7748a5739605636 /tests/DynamicCodeLoggerIntegrationTests/src/cpp/test_executable.cpp
parente72d456c3f39ae90cdc3063d8f6b03434c134c34 (diff)
Fix exception handling in getState() binder cache
Bug: 153103051 A binder cache query function cannot compute a result based on any data that is not known to the binder server. If the code depends on local data that can change, then invalidation will not work properly. The getState() method returns OFF if the bluetooth service is unavailable. This computation now occurs in the getState() method, outside of the binder cache query() method. The query method converts RemoteExceptions to RuntimeExceptions. Then, the conversion is reversed in getState(). This double conversion is needed because the cache query() method has no throw spec. Test: Run 'atest BluetoothInstrumentationTests' with a special debug image that enables binder cache VERIFY. The test found no cache inconsistencies. Change-Id: I80db86f66d8b51fa94207824c8b15972a9066ef5
Diffstat (limited to 'tests/DynamicCodeLoggerIntegrationTests/src/cpp/test_executable.cpp')
0 files changed, 0 insertions, 0 deletions