]> git-server-git.apps.pok.os.sepia.ceph.com Git - ceph.git/commitdiff
messages/MMonElection: drop old compat cruft
authorSage Weil <sage@redhat.com>
Wed, 12 Apr 2017 02:43:38 +0000 (22:43 -0400)
committerSage Weil <sage@redhat.com>
Fri, 21 Apr 2017 20:00:39 +0000 (16:00 -0400)
v5 was 8025fb33add620cb89f795281067c5bddf0467b5 (pre-firefly); v6 was
34b4ad730bfb5a90760705553415582ac01a4312 (pre-kraken).

Signed-off-by: Sage Weil <sage@redhat.com>
src/messages/MMonElection.h

index 89f10a81a2b2d7ac920e5f402374b9c51df72125..79503875e264490f3b08152b0ba7d5a1dff43d38 100644 (file)
@@ -23,7 +23,7 @@
 class MMonElection : public Message {
 
   static const int HEAD_VERSION = 6;
-  static const int COMPAT_VERSION = 2;
+  static const int COMPAT_VERSION = 5;
 
 public:
   static const int OP_PROPOSE = 1;
@@ -103,24 +103,15 @@ public:
   }
   void decode_payload() override {
     bufferlist::iterator p = payload.begin();
-    if (header.version >= 2)
-      ::decode(fsid, p);
-    else
-      memset(&fsid, 0, sizeof(fsid));
+    ::decode(fsid, p);
     ::decode(op, p);
     ::decode(epoch, p);
     ::decode(monmap_bl, p);
     ::decode(quorum, p);
-    if (header.version >= 3)
-      ::decode(quorum_features, p);
-    else
-      quorum_features = 0;
-    if (header.version >= 4) {
-      ::decode(defunct_one, p);
-      ::decode(defunct_two, p);
-    }
-    if (header.version >= 5)
-      ::decode(sharing_bl, p);
+    ::decode(quorum_features, p);
+    ::decode(defunct_one, p);
+    ::decode(defunct_two, p);
+    ::decode(sharing_bl, p);
     if (header.version >= 6)
       ::decode(mon_features, p);
   }