COM-74: Expose _PEP_enc_format to app for EncryptMessage COM-74
authorMarkus Schaber <markus@pep-security.net>
Wed, 07 Feb 2018 19:42:45 +0100
branchCOM-74
changeset 2720cd9b4cde17c
parent 271 92866cd8b0c4
child 273 30be98685afa
COM-74: Expose _PEP_enc_format to app for EncryptMessage

- Suppress exception in the now-common case of PEP_KEY_NOT_FOUND as requested by Thomas.
CpEpEngine.cpp
     1.1 --- a/CpEpEngine.cpp	Wed Feb 07 19:33:59 2018 +0100
     1.2 +++ b/CpEpEngine.cpp	Wed Feb 07 19:42:45 2018 +0100
     1.3 @@ -551,7 +551,7 @@
     1.4          ::free_identity(_ident);
     1.5          return S_OK;
     1.6      }
     1.7 -    else if (status == PEP_GET_KEY_FAILED) {
     1.8 +    else if (status == PEP_GET_KEY_FAILED || status == PEP_KEY_NOT_FOUND) {
     1.9          if (_ident->fpr) {
    1.10              pEp_free(_ident->fpr);
    1.11              _ident->fpr = NULL;