Google-style override & virtual

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

Google C++ Style dictates that methods which override base class or
interface methods should be declared "override" but not "virtual". Since
our codebase has not had access to "override" until now, many of our
classes do not follow this rule. I've updated as many places as I could
find to follow Google C++ Style, which should hopefully help us catch
errors better in the future.

Bug: 111851141
Test: CE CDM Unit Tests
Test: Android Unit Tests
Change-Id: Ic23e2e482e967256da306791532b5fec7b81b2f2
This commit is contained in:
John W. Bruce
2018-12-06 09:01:18 -08:00
parent 5629a646d8
commit b771d93514
19 changed files with 111 additions and 112 deletions

View File

@@ -207,7 +207,7 @@ class CdmLicenseTest : public WvCdmTestBase {
protected:
CdmLicenseTest(const std::string& pssh = (kCencInitDataHdr + kCencPssh))
: pssh_(pssh) {}
virtual void SetUp() {
void SetUp() override {
WvCdmTestBase::SetUp();
clock_ = new MockClock();
crypto_session_ = new MockCryptoSession(&crypto_metrics_);
@@ -219,7 +219,7 @@ class CdmLicenseTest : public WvCdmTestBase {
DoAll(SetArgPointee<0>(kDefaultSupportedCertTypes), Return(true)));
}
virtual void TearDown() {
void TearDown() override {
if (cdm_license_) delete cdm_license_;
if (policy_engine_) delete policy_engine_;
if (init_data_) delete init_data_;