diff options
author | trinity-1686a <trinity@deuxfleurs.fr> | 2022-06-08 00:30:56 +0200 |
---|---|---|
committer | trinity-1686a <trinity@deuxfleurs.fr> | 2022-06-08 09:54:38 +0200 |
commit | 4745e7c4ba5665d3303ae567087781778cec9c34 (patch) | |
tree | 667effc91ab5674360ef0211ab32b533a35f36af /src/util.rs | |
parent | fb5462ecdb6b5731a63a902519d3ec9b1061b8dd (diff) | |
download | netapp-4745e7c4ba5665d3303ae567087781778cec9c34.tar.gz netapp-4745e7c4ba5665d3303ae567087781778cec9c34.zip |
further work on streams
most changes still required are related to error handling
Diffstat (limited to 'src/util.rs')
-rw-r--r-- | src/util.rs | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/src/util.rs b/src/util.rs index 4333080..02b4e7d 100644 --- a/src/util.rs +++ b/src/util.rs @@ -8,6 +8,8 @@ use futures::Stream; use log::info; +use serde::Serialize; + use tokio::sync::watch; /// A node's identifier, which is also its public cryptographic key @@ -34,7 +36,8 @@ where let mut se = rmp_serde::Serializer::new(&mut wr) .with_struct_map() .with_string_variants(); - let (_, stream) = val.serialize_msg(&mut se)?; + let (val, stream) = val.serialize_msg(); + val.serialize(&mut se)?; Ok((wr, stream)) } |