diff options
author | Justus Winter <justus@sequoia-pgp.org> | 2020-11-04 15:11:25 +0100 |
---|---|---|
committer | Justus Winter <justus@sequoia-pgp.org> | 2020-11-04 16:20:27 +0100 |
commit | 32b93364165ddc24d29ea7319db6a21b6fe5a515 (patch) | |
tree | 24c31c2afe783b86c3a81ed3fb9bccca4cf54407 /openpgp/examples/encrypt-for.rs | |
parent | 9edc6b6f7e9e05bfd4d6ac0573c2b81f934ebaae (diff) |
make stream::Message::finalize asyncjustus/fix-607
- For sop which only uses local keys, we do not need a runtime.
Diffstat (limited to 'openpgp/examples/encrypt-for.rs')
-rw-r--r-- | openpgp/examples/encrypt-for.rs | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/openpgp/examples/encrypt-for.rs b/openpgp/examples/encrypt-for.rs index 0b0bc998..c68ff77b 100644 --- a/openpgp/examples/encrypt-for.rs +++ b/openpgp/examples/encrypt-for.rs @@ -5,6 +5,7 @@ use std::env; use std::io; use anyhow::Context; +use futures::FutureExt; use sequoia_openpgp as openpgp; @@ -81,7 +82,7 @@ fn main() -> openpgp::Result<()> { // Finally, finalize the OpenPGP message by tearing down the // writer stack. - message.finalize()?; + message.finalize().now_or_never().unwrap()?; Ok(()) } |