]> git.proxmox.com Git - ceph.git/blobdiff - ceph/src/rocksdb/options/options_parser.cc
import 14.2.4 nautilus point release
[ceph.git] / ceph / src / rocksdb / options / options_parser.cc
index f9144b67d77549e1ac31d715ebf1c6a80d1340a2..2a85fa5343fd4329a2b4b71157f497c46464c1c6 100644 (file)
@@ -48,7 +48,7 @@ Status PersistRocksDBOptions(const DBOptions& db_opt,
   if (!s.ok()) {
     return s;
   }
-  unique_ptr<WritableFileWriter> writable;
+  std::unique_ptr<WritableFileWriter> writable;
   writable.reset(new WritableFileWriter(std::move(wf), file_name, EnvOptions(),
                                         nullptr /* statistics */));
 
@@ -500,6 +500,16 @@ bool AreEqualOptions(
     case OptionType::kInt:
       return (*reinterpret_cast<const int*>(offset1) ==
               *reinterpret_cast<const int*>(offset2));
+    case OptionType::kInt32T:
+      return (*reinterpret_cast<const int32_t*>(offset1) ==
+              *reinterpret_cast<const int32_t*>(offset2));
+    case OptionType::kInt64T:
+      {
+        int64_t v1, v2;
+        GetUnaligned(reinterpret_cast<const int64_t*>(offset1), &v1);
+        GetUnaligned(reinterpret_cast<const int64_t*>(offset2), &v2);
+        return (v1 == v2);
+      }
     case OptionType::kVectorInt:
       return (*reinterpret_cast<const std::vector<int>*>(offset1) ==
               *reinterpret_cast<const std::vector<int>*>(offset2));
@@ -574,7 +584,7 @@ bool AreEqualOptions(
       CompactionOptionsFIFO rhs =
           *reinterpret_cast<const CompactionOptionsFIFO*>(offset2);
       if (lhs.max_table_files_size == rhs.max_table_files_size &&
-          lhs.ttl == rhs.ttl && lhs.allow_compaction == rhs.allow_compaction) {
+          lhs.allow_compaction == rhs.allow_compaction) {
         return true;
       }
       return false;