From 7d53746ea64bef379823e83c28d2be0680337603 Mon Sep 17 00:00:00 2001 From: Werner Koch Date: Thu, 15 Apr 2004 15:18:30 +0000 Subject: [PATCH] (gpgme_get_key): Return an error if FPR is NULL. --- trunk/gpgme/ChangeLog | 4 ++++ trunk/gpgme/keylist.c | 2 +- 2 files changed, 5 insertions(+), 1 deletion(-) diff --git a/trunk/gpgme/ChangeLog b/trunk/gpgme/ChangeLog index 26c4630..94e407f 100644 --- a/trunk/gpgme/ChangeLog +++ b/trunk/gpgme/ChangeLog @@ -1,3 +1,7 @@ +2004-04-15 Werner Koch + + * keylist.c (gpgme_get_key): Return an error if FPR is NULL. + 2004-04-08 Werner Koch * verify.c (_gpgme_verify_status_handler): Ignore the error status diff --git a/trunk/gpgme/keylist.c b/trunk/gpgme/keylist.c index 99499de..eb8597e 100644 --- a/trunk/gpgme/keylist.c +++ b/trunk/gpgme/keylist.c @@ -838,7 +838,7 @@ gpgme_get_key (gpgme_ctx_t ctx, const char *fpr, gpgme_key_t *r_key, gpgme_error_t err; gpgme_key_t key; - if (!ctx || !r_key) + if (!ctx || !r_key || !fpr) return gpg_error (GPG_ERR_INV_VALUE); if (strlen (fpr) < 16) /* We have at least a key ID. */ -- 2.26.2