diff options
author | Justus Winter <justus@sequoia-pgp.org> | 2018-06-25 11:25:23 +0200 |
---|---|---|
committer | Justus Winter <justus@sequoia-pgp.org> | 2018-06-25 11:50:06 +0200 |
commit | 0bf1721ae721dfc439a88c3c3e22b697a3606643 (patch) | |
tree | 90e6a8c6d52533b7e46340608a9c9f160236bb4b /ffi | |
parent | a7ef3e7c543aca585de373b5cfb9c6e8a46f75f3 (diff) |
openpgp: Drop the alias for Kind::SecretKey.
- Having an alias in the enum seems not worth the trouble, e.g. it
complicates equality.
Diffstat (limited to 'ffi')
-rw-r--r-- | ffi/include/sequoia/openpgp.h | 5 | ||||
-rw-r--r-- | ffi/src/openpgp.rs | 9 |
2 files changed, 4 insertions, 10 deletions
diff --git a/ffi/include/sequoia/openpgp.h b/ffi/include/sequoia/openpgp.h index 50eeec4d..a2398a92 100644 --- a/ffi/include/sequoia/openpgp.h +++ b/ffi/include/sequoia/openpgp.h @@ -125,11 +125,6 @@ typedef enum sq_armor_kind { /*/ /// A transferable secret key. /*/ - SQ_ARMOR_KIND_PRIVATEKEY, - - /*/ - /// Alias for PrivateKey. - /*/ SQ_ARMOR_KIND_SECRETKEY, /*/ diff --git a/ffi/src/openpgp.rs b/ffi/src/openpgp.rs index 964f43fd..3fd9cee9 100644 --- a/ffi/src/openpgp.rs +++ b/ffi/src/openpgp.rs @@ -193,11 +193,10 @@ fn int_to_kind(kind: c_int) -> armor::Kind { match kind { 0 => armor::Kind::Message, 1 => armor::Kind::PublicKey, - 2 => armor::Kind::PrivateKey, - 3 => armor::Kind::SecretKey, - 4 => armor::Kind::Signature, - 5 => armor::Kind::File, - 6 => armor::Kind::Any, + 2 => armor::Kind::SecretKey, + 3 => armor::Kind::Signature, + 4 => armor::Kind::File, + 5 => armor::Kind::Any, _ => panic!("Bad kind: {}", kind), } } |