diff options
author | Wiktor Kwapisiewicz <wiktor@metacode.biz> | 2020-04-01 15:04:14 +0200 |
---|---|---|
committer | Wiktor Kwapisiewicz <wiktor@metacode.biz> | 2020-04-03 14:22:34 +0200 |
commit | 49315e0b3df7793d6f35901e77ab76341a7f3770 (patch) | |
tree | 8b635d12d49a69b61cefa866e1e4bdf97445e664 /openpgp-ffi/src/cert.rs | |
parent | 6b4207285b182ca1a94f55608455646c1e36b859 (diff) |
openpgp: Convert Cert::from_packet_parser into TryFrom<PacketParserResult>
Diffstat (limited to 'openpgp-ffi/src/cert.rs')
-rw-r--r-- | openpgp-ffi/src/cert.rs | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/openpgp-ffi/src/cert.rs b/openpgp-ffi/src/cert.rs index 89c61199..cb6642d3 100644 --- a/openpgp-ffi/src/cert.rs +++ b/openpgp-ffi/src/cert.rs @@ -5,6 +5,7 @@ //! [`sequoia-openpgp::Cert`]: ../../../sequoia_openpgp/cert/struct.Cert.html //! [related functionality]: ../../../sequoia_openpgp/cert/index.html +use std::convert::TryFrom; use std::ptr; use std::slice; use libc::{c_char, c_int, size_t, time_t}; @@ -80,7 +81,7 @@ fn pgp_cert_from_packet_parser(errp: Option<&mut *mut crate::error::Error>, { let ppr = ffi_param_move!(ppr); - openpgp::Cert::from_packet_parser(*ppr).move_into_raw(errp) + openpgp::Cert::try_from(*ppr).move_into_raw(errp) } /// Merges `other` into `cert`. |