From bcf32431ceb64818a4a8457b4b4c04db9baf1397 Mon Sep 17 00:00:00 2001 From: chengzhl Date: Sat, 16 Sep 2023 09:02:48 +0800 Subject: [PATCH 1/2] Fix build error in Visual Studio 17.7 --- src/messages.cpp | 2 +- src/treekem.cpp | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/src/messages.cpp b/src/messages.cpp index 8daa652d..f064a247 100644 --- a/src/messages.cpp +++ b/src/messages.cpp @@ -160,7 +160,7 @@ Welcome::encrypt(const KeyPackage& kp, const std::optional& path_secret) { auto gs = GroupSecrets{ _joiner_secret, std::nullopt, _psks }; if (path_secret) { - gs.path_secret = { opt::get(path_secret) }; + gs.path_secret = GroupSecrets::PathSecret{ opt::get(path_secret) }; } auto gs_data = tls::marshal(gs); diff --git a/src/treekem.cpp b/src/treekem.cpp index c8c56688..485b8d9c 100644 --- a/src/treekem.cpp +++ b/src/treekem.cpp @@ -492,7 +492,7 @@ TreeKEMPublicKey::merge(LeafIndex from, const UpdatePath& path) parent_hash = ph[i + 1]; } - node_at(n).node = { ParentNode{ + node_at(n).node = Node{ ParentNode{ path.nodes[i].public_key, parent_hash, {} } }; } From 5cb0d428dda3031e1a8e87d168e9a5a9c3cd1dd2 Mon Sep 17 00:00:00 2001 From: liangxil Date: Sun, 17 Sep 2023 07:08:07 +0800 Subject: [PATCH 2/2] fix format issue --- src/treekem.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/treekem.cpp b/src/treekem.cpp index 485b8d9c..53aeea1c 100644 --- a/src/treekem.cpp +++ b/src/treekem.cpp @@ -492,8 +492,8 @@ TreeKEMPublicKey::merge(LeafIndex from, const UpdatePath& path) parent_hash = ph[i + 1]; } - node_at(n).node = Node{ ParentNode{ - path.nodes[i].public_key, parent_hash, {} } }; + node_at(n).node = + Node{ ParentNode{ path.nodes[i].public_key, parent_hash, {} } }; } set_hash_all();