]> git.proxmox.com Git - ceph.git/blobdiff - ceph/src/messages/MOSDPGRemove.h
update sources to v12.1.3
[ceph.git] / ceph / src / messages / MOSDPGRemove.h
index 5a716b4700d19084a9a48d89b9c4962b0e214323..f692ad428c361edb0d01456a38049855eacdbc0c 100644 (file)
@@ -25,7 +25,7 @@ class MOSDPGRemove : public Message {
   static const int HEAD_VERSION = 3;
   static const int COMPAT_VERSION = 2;
 
-  epoch_t epoch;
+  epoch_t epoch = 0;
 
  public:
   vector<spg_t> pg_list;
@@ -46,7 +46,9 @@ public:
   const char *get_type_name() const override { return "PGrm"; }
 
   void encode_payload(uint64_t features) override {
-    if (!HAVE_FEATURE(features, SERVER_LUMINOUS)) {
+    if (HAVE_FEATURE(features, SERVER_LUMINOUS)) {
+      header.version = HEAD_VERSION;
+    } else {
       // for jewel+kraken
       header.version = 2;
       ::encode(epoch, payload);