[PeopleService] Catch exception when failed to query call log.

It's unnecessary to throw exception when failed to query call
log in PeopleService. So catch this exception to avoid system
server crash.

Bug: 204923224
Test: PeopleServiceTest
Change-Id: I77ee31ff456455721c3401f36d4a79390db2f9b5
This commit is contained in:
qinyige1 2021-11-03 17:39:12 +08:00
parent 27c03c7f68
commit 28367ba78a

View File

@ -93,6 +93,9 @@ class CallLogQueryHelper {
hasResults = true;
}
}
} catch (SecurityException ex) {
Slog.e(TAG, "Query call log failed: " + ex);
return false;
}
return hasResults;
}