summaryrefslogtreecommitdiffstats
path: root/g10/export.c
diff options
context:
space:
mode:
authorNIIBE Yutaka <gniibe@fsij.org>2017-04-17 02:15:13 +0200
committerNIIBE Yutaka <gniibe@fsij.org>2017-04-17 02:15:13 +0200
commit0dec0cc281dfa26db89f8cc5ee002dea5c2b2e81 (patch)
treea5211becd35f1dccfd139bcf210f0ae7921ac527 /g10/export.c
parentg10: Fix import/export filter property match. (diff)
downloadgnupg2-0dec0cc281dfa26db89f8cc5ee002dea5c2b2e81.tar.xz
gnupg2-0dec0cc281dfa26db89f8cc5ee002dea5c2b2e81.zip
g10: Minor fixes.
* g10/export.c (cleartext_secret_key_to_openpgp): No initialization. (do_export_one_keyblock): Initialize with GPG_ERR_NOT_FOUND. * g10/getkey.c (get_best_pubkey_byname): Add non-null check. * g10/tofu.c (tofu_set_policy): ERR initialize to 0. Signed-off-by: NIIBE Yutaka <gniibe@fsij.org>
Diffstat (limited to 'g10/export.c')
-rw-r--r--g10/export.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/g10/export.c b/g10/export.c
index 9b203e322..ce79a2ffd 100644
--- a/g10/export.c
+++ b/g10/export.c
@@ -580,7 +580,7 @@ canon_pk_algo (enum gcry_pk_algos algo)
static gpg_error_t
cleartext_secret_key_to_openpgp (gcry_sexp_t s_key, PKT_public_key *pk)
{
- gpg_error_t err = gpg_error (GPG_ERR_NOT_IMPLEMENTED);
+ gpg_error_t err;
gcry_sexp_t top_list;
gcry_sexp_t key = NULL;
char *key_type = NULL;
@@ -1539,7 +1539,7 @@ do_export_one_keyblock (ctrl_t ctrl, kbnode_t keyblock, u32 *keyid,
KEYDB_SEARCH_DESC *desc, size_t ndesc,
size_t descindex, gcry_cipher_hd_t cipherhd)
{
- gpg_error_t err;
+ gpg_error_t err = gpg_error (GPG_ERR_NOT_FOUND);
char *cache_nonce = NULL;
subkey_list_t subkey_list = NULL; /* Track already processed subkeys. */
int skip_until_subkey = 0;