Add missing override keywords

(This is a merge of http://go/wvgerrit/139629.)

This patch fixes several places where the override keyword was missing.
These were found when future patches that enable stricter checking of
the override keyword were enabled. There are two basic categories of
missing override:

* Destructors found to be overriding a virtual destructor without using
  the override keyword.
* Test methods overriding methods on test-only or mock objects.

Some of these were previously marked as virtual, following our pre-C++11
style guidelines, but this is not necessary now that we have override.

Bug: 207684988
Test: x86-64 build
Change-Id: I09aa499bd3ea80d925e2fc422290d61eb005a769
This commit is contained in:
John "Juce" Bruce
2021-12-01 11:55:32 -08:00
parent 8574a4b98c
commit bfd299a4be
11 changed files with 15 additions and 13 deletions

View File

@@ -248,7 +248,8 @@ CdmResponseType TestCryptoSession::GenerateNonce(uint32_t* nonce) {
}
class TestCryptoSessionFactory : public CryptoSessionFactory {
CryptoSession* MakeCryptoSession(metrics::CryptoMetrics* crypto_metrics) {
CryptoSession* MakeCryptoSession(
metrics::CryptoMetrics* crypto_metrics) override {
// We need to add extra locking here because we need to make sure that there
// are no other OEMCrypto calls between OEMCrypto_Initialize and
// InstallTestRootOfTrust. OEMCrypto_Initialize is called in the production