Merge "Called onError() when HotwordDetectionService process died" into sc-dev

This commit is contained in:
TreeHugger Robot
2021-06-09 11:16:32 +00:00
committed by Android (Google) Code Review

View File

@@ -131,6 +131,17 @@ final class HotwordDetectionConnection {
protected long getAutoDisconnectTimeoutMs() { protected long getAutoDisconnectTimeoutMs() {
return -1; return -1;
} }
@Override
public void binderDied() {
super.binderDied();
Slog.w(TAG, "binderDied");
try {
callback.onError(-1);
} catch (RemoteException e) {
Slog.w(TAG, "Failed to report onError status: " + e);
}
}
}; };
mRemoteHotwordDetectionService.connect(); mRemoteHotwordDetectionService.connect();
if (callback == null) { if (callback == null) {