diff options
author | Werner Koch <[email protected]> | 2001-07-31 15:21:58 +0000 |
---|---|---|
committer | Werner Koch <[email protected]> | 2001-07-31 15:21:58 +0000 |
commit | ec8c9d9494494656b2618ecfc43ec485dc931ec4 (patch) | |
tree | 6b1c0a24c103fe809693d52ef7cdd1b4ddd36378 /gpgme/encrypt.c | |
parent | Added 2 examples (diff) | |
download | gpgme-ec8c9d9494494656b2618ecfc43ec485dc931ec4.tar.gz gpgme-ec8c9d9494494656b2618ecfc43ec485dc931ec4.zip |
A couple of minor changes and a short README for Gpgcom
Diffstat (limited to '')
-rw-r--r-- | gpgme/encrypt.c | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/gpgme/encrypt.c b/gpgme/encrypt.c index 3fe60a62..bff4153d 100644 --- a/gpgme/encrypt.c +++ b/gpgme/encrypt.c @@ -70,7 +70,7 @@ gpgme_op_encrypt_start ( GpgmeCtx c, GpgmeRecipients recp, for ( i=0; i < c->verbosity; i++ ) _gpgme_gpg_add_arg ( c->gpg, "--verbose" ); /* If we know that all recipients are valid (full or ultimate trust) - * we can pass suppress further checks */ + * we can suppress further checks */ if ( _gpgme_recipients_all_valid (recp) ) _gpgme_gpg_add_arg ( c->gpg, "--always-trust" ); @@ -127,6 +127,12 @@ gpgme_op_encrypt ( GpgmeCtx c, GpgmeRecipients recp, if ( !rc ) { gpgme_wait (c, 1); c->pending = 0; + /* FIXME: gpg does not return status info for invalid + * recipients, so we simply check whether we got any output at + * all and if not assume that we don't have valid recipients + * */ + if (gpgme_data_get_type (out) == GPGME_DATA_TYPE_NONE) + rc = mk_error (No_Recipients); } return rc; } |