Add protocol revision number in protocol hash

This commit is contained in:
Guillaume Meunier
2024-11-10 21:17:08 +01:00
parent 97bacfcd35
commit c5db0258be
3 changed files with 8 additions and 2 deletions
+5 -1
View File
@@ -882,10 +882,14 @@ struct serialization_traits<data_holder>
};
template <typename T>
constexpr uint64_t serialization_type_hash()
constexpr uint64_t serialization_type_hash(int revision)
{
details::hash_context h;
serialization_traits<T>::type_hash(h);
if (revision)
h.feed(revision);
return h.hash;
}