diff options
| author | Paul Florence <[email protected]> | 2017-11-10 10:05:52 -0500 |
|---|---|---|
| committer | Paul Florence <[email protected]> | 2017-11-10 10:05:52 -0500 |
| commit | 0bae121e1268565eb29e90e68b8c5e98ab1fe979 (patch) | |
| tree | ac7fc87f39f98b905fa8c388b498749f28b18413 /openssl/src/asn1.rs | |
| parent | Merge pull request #757 from bvinc/master (diff) | |
| download | rust-openssl-0bae121e1268565eb29e90e68b8c5e98ab1fe979.tar.xz rust-openssl-0bae121e1268565eb29e90e68b8c5e98ab1fe979.zip | |
Added a macro that wraps foreign type, and impl Send and Sync for both,
the borrowed type and the owned one.
Replaced all invocation of `foreign_type` by `foreign_type_and_impl_send_sync`.
Diffstat (limited to 'openssl/src/asn1.rs')
| -rw-r--r-- | openssl/src/asn1.rs | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/openssl/src/asn1.rs b/openssl/src/asn1.rs index 27913aa6..d129235a 100644 --- a/openssl/src/asn1.rs +++ b/openssl/src/asn1.rs @@ -38,7 +38,7 @@ use error::ErrorStack; use nid::Nid; use string::OpensslString; -foreign_type! { +foreign_type_and_impl_send_sync! { type CType = ffi::ASN1_GENERALIZEDTIME; fn drop = ffi::ASN1_GENERALIZEDTIME_free; @@ -73,7 +73,7 @@ impl fmt::Display for Asn1GeneralizedTimeRef { } } -foreign_type! { +foreign_type_and_impl_send_sync! { type CType = ffi::ASN1_TIME; fn drop = ffi::ASN1_TIME_free; /// Time storage and comparison @@ -119,7 +119,7 @@ impl Asn1Time { } } -foreign_type! { +foreign_type_and_impl_send_sync! { type CType = ffi::ASN1_STRING; fn drop = ffi::ASN1_STRING_free; /// Primary ASN.1 type used by OpenSSL @@ -170,7 +170,7 @@ impl Asn1StringRef { } } -foreign_type! { +foreign_type_and_impl_send_sync! { type CType = ffi::ASN1_INTEGER; fn drop = ffi::ASN1_INTEGER_free; @@ -211,7 +211,7 @@ impl Asn1IntegerRef { } } -foreign_type! { +foreign_type_and_impl_send_sync! { type CType = ffi::ASN1_BIT_STRING; fn drop = ffi::ASN1_BIT_STRING_free; /// Sequence of bytes @@ -238,7 +238,7 @@ impl Asn1BitStringRef { } } -foreign_type! { +foreign_type_and_impl_send_sync! { type CType = ffi::ASN1_OBJECT; fn drop = ffi::ASN1_OBJECT_free; |