From dd44935e5a6ef1011d6ec6bc9bd7722187e511ec Mon Sep 17 00:00:00 2001 From: Wiktor Kwapisiewicz Date: Thu, 9 Jun 2022 09:06:46 +0200 Subject: openpgp: Rename PacketParser::{set_,}encrypted to processed. - Convert `encrypted` to `processed`. - Since `set_encrypted` is internal API it was directly renamed without forwarder stub. - `encrypted()` is public API thus the old function is converted to a forwarder of the negation of `processed()`. - `unprocessed()` marked as deprecated. - Update docs and NEWS file. - Fixes #845. --- openpgp/src/parse/stream.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'openpgp/src/parse') diff --git a/openpgp/src/parse/stream.rs b/openpgp/src/parse/stream.rs index 36459f9c..8013e107 100644 --- a/openpgp/src/parse/stream.rs +++ b/openpgp/src/parse/stream.rs @@ -2402,7 +2402,7 @@ impl<'a, H: VerificationHelper + DecryptionHelper> Decryptor<'a, H> { sym_algo_hint, decryption_proxy)?; } - if pp.encrypted() { + if ! pp.processed() { return Err( Error::MissingSessionKey( "No session key decrypted".into()).into()); -- cgit v1.2.3