summaryrefslogtreecommitdiffstats
path: root/openpgp/src/policy.rs
diff options
context:
space:
mode:
authorAzul <azul@riseup.net>2020-12-04 20:06:17 +0100
committerAzul <azul@riseup.net>2020-12-08 10:35:58 +0100
commitb956d36cb50cac28aa9da0e373fb33c9a4c120af (patch)
treec20bb42230aed97494b6abe494bc8e22053f58a6 /openpgp/src/policy.rs
parent4a971af5abe70d41485df141a3d9fa97eaab5f1c (diff)
openpgp: Ensure public types are Send and Sync.
- See #627.
Diffstat (limited to 'openpgp/src/policy.rs')
-rw-r--r--openpgp/src/policy.rs4
1 files changed, 4 insertions, 0 deletions
diff --git a/openpgp/src/policy.rs b/openpgp/src/policy.rs
index cc268d17..f626078b 100644
--- a/openpgp/src/policy.rs
+++ b/openpgp/src/policy.rs
@@ -188,6 +188,8 @@ pub struct StandardPolicy<'a> {
asymmetric_algos: AsymmetricAlgorithmCutoffList,
}
+assert_send_and_sync!{StandardPolicy<'a>, 'a}
+
impl<'a> Default for StandardPolicy<'a> {
fn default() -> Self {
Self::new()
@@ -954,6 +956,8 @@ impl From<AsymmetricAlgorithm> for u8 {
pub struct NullPolicy {
}
+assert_send_and_sync!{NullPolicy}
+
impl NullPolicy {
/// Instantiates a new `NullPolicy`.
pub const fn new() -> Self {