From ab9f6cea59bfae234ca45159079087403eb2ed43 Mon Sep 17 00:00:00 2001 From: liuchang0812 Date: Wed, 22 Feb 2017 19:45:41 +0800 Subject: common: add override in msg subsystem Signed-off-by: liuchang0812 --- src/messages/MMonElection.h | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) (limited to 'src/messages/MMonElection.h') diff --git a/src/messages/MMonElection.h b/src/messages/MMonElection.h index 97ab440d6fd..89f10a81a2b 100644 --- a/src/messages/MMonElection.h +++ b/src/messages/MMonElection.h @@ -73,15 +73,15 @@ public: m->encode(monmap_bl, CEPH_FEATURES_ALL); } private: - ~MMonElection() {} + ~MMonElection() override {} public: - const char *get_type_name() const { return "election"; } - void print(ostream& out) const { + const char *get_type_name() const override { return "election"; } + void print(ostream& out) const override { out << "election(" << fsid << " " << get_opname(op) << " " << epoch << ")"; } - void encode_payload(uint64_t features) { + void encode_payload(uint64_t features) override { if (monmap_bl.length() && (features != CEPH_FEATURES_ALL)) { // reencode old-format monmap MonMap t; @@ -101,7 +101,7 @@ public: ::encode(sharing_bl, payload); ::encode(mon_features, payload); } - void decode_payload() { + void decode_payload() override { bufferlist::iterator p = payload.begin(); if (header.version >= 2) ::decode(fsid, p); -- cgit v1.2.3