summaryrefslogtreecommitdiffstats
path: root/g10/export.c
diff options
context:
space:
mode:
authorWerner Koch <wk@gnupg.org>2020-02-11 14:38:03 +0100
committerWerner Koch <wk@gnupg.org>2020-02-11 14:40:54 +0100
commit24095101a5069f15a9aea7512498ac436a76814a (patch)
tree58b6e8f20ed4332599cba202003c52062d800b70 /g10/export.c
parentdoc: Improve the warning section of the gpg man page. (diff)
downloadgnupg2-24095101a5069f15a9aea7512498ac436a76814a.tar.xz
gnupg2-24095101a5069f15a9aea7512498ac436a76814a.zip
common: Extend the openpgp_curve_to_oid function.
* common/openpgp-oid.c (openpgp_curve_to_oid): Add optional arg R_NBITS. Change all callers. -- In particular for ed25519 and cv25519 it is quite useful to have an ability to get the required algorithm.
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 3517be72c..9160680d7 100644
--- a/g10/export.c
+++ b/g10/export.c
@@ -517,7 +517,7 @@ match_curve_skey_pk (gcry_sexp_t s_key, PKT_public_key *pk)
log_error ("no curve name\n");
return gpg_error (GPG_ERR_UNKNOWN_CURVE);
}
- oidstr = openpgp_curve_to_oid (curve_str, NULL);
+ oidstr = openpgp_curve_to_oid (curve_str, NULL, NULL);
if (!oidstr)
{
log_error ("no OID known for curve '%s'\n", curve_str);
@@ -1023,7 +1023,7 @@ transfer_format_to_openpgp (gcry_sexp_t s_pgp, PKT_public_key *pk)
goto leave;
}
- oidstr = openpgp_curve_to_oid (curve, NULL);
+ oidstr = openpgp_curve_to_oid (curve, NULL, NULL);
if (!oidstr)
{
log_error ("no OID known for curve '%s'\n", curve);