summaryrefslogtreecommitdiffstats
path: root/openpgp/src/packet/user_attribute.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/packet/user_attribute.rs
parent4a971af5abe70d41485df141a3d9fa97eaab5f1c (diff)
openpgp: Ensure public types are Send and Sync.
- See #627.
Diffstat (limited to 'openpgp/src/packet/user_attribute.rs')
-rw-r--r--openpgp/src/packet/user_attribute.rs4
1 files changed, 4 insertions, 0 deletions
diff --git a/openpgp/src/packet/user_attribute.rs b/openpgp/src/packet/user_attribute.rs
index 246c1be6..09fc8749 100644
--- a/openpgp/src/packet/user_attribute.rs
+++ b/openpgp/src/packet/user_attribute.rs
@@ -38,6 +38,7 @@ pub struct UserAttribute {
/// The user attribute.
value: Vec<u8>,
}
+assert_send_and_sync!{UserAttribute}
impl From<Vec<u8>> for UserAttribute {
fn from(u: Vec<u8>) -> Self {
@@ -117,6 +118,7 @@ impl Arbitrary for UserAttribute {
pub struct SubpacketIterator<'a> {
reader: buffered_reader::Memory<'a, ()>,
}
+assert_send_and_sync!{SubpacketIterator<'a>, 'a}
impl<'a> Iterator for SubpacketIterator<'a> {
type Item = Result<Subpacket>;
@@ -191,6 +193,7 @@ pub enum Subpacket {
/// Unknown subpacket.
Unknown(u8, Box<[u8]>),
}
+assert_send_and_sync!{Subpacket}
#[cfg(test)]
impl Arbitrary for Subpacket {
@@ -224,6 +227,7 @@ pub enum Image {
/// Unknown image format.
Unknown(u8, Box<[u8]>),
}
+assert_send_and_sync!{Image}
#[cfg(test)]
impl Arbitrary for Image {