summaryrefslogtreecommitdiffstats
path: root/g10/keyedit.c
diff options
context:
space:
mode:
authorWerner Koch <wk@gnupg.org>2019-05-13 12:38:32 +0200
committerWerner Koch <wk@gnupg.org>2019-05-13 12:39:17 +0200
commitd07666412d4317460c6f03b3ffd03edf4a715ef7 (patch)
tree3cb40ac32c45abe181769091b64726a9cb673dae /g10/keyedit.c
parentbuild: Update m4/iconv.m4. (diff)
downloadgnupg2-d07666412d4317460c6f03b3ffd03edf4a715ef7.tar.xz
gnupg2-d07666412d4317460c6f03b3ffd03edf4a715ef7.zip
gpg: Cleanup use of make_keysig_packet.
* g10/sign.c (make_keysig_packet): Remove obsolete arg diegst_algo which was always passed as 0. Change all callers. * g10/gpgcompose.c (signature): Warn when trying to set a digest algo. -- Signed-off-by: Werner Koch <wk@gnupg.org>
Diffstat (limited to 'g10/keyedit.c')
-rw-r--r--g10/keyedit.c19
1 files changed, 10 insertions, 9 deletions
diff --git a/g10/keyedit.c b/g10/keyedit.c
index c28a565b1..7f4c5a509 100644
--- a/g10/keyedit.c
+++ b/g10/keyedit.c
@@ -1012,7 +1012,8 @@ sign_uids (ctrl_t ctrl, estream_t fp,
node->pkt->pkt.user_id,
NULL,
pk,
- 0x13, 0, 0, 0,
+ 0x13,
+ 0, 0,
keygen_add_std_prefs, primary_pk,
NULL);
else
@@ -1020,7 +1021,7 @@ sign_uids (ctrl_t ctrl, estream_t fp,
node->pkt->pkt.user_id,
NULL,
pk,
- class, 0,
+ class,
timestamp, duration,
sign_mk_attrib, &attrib,
NULL);
@@ -3991,7 +3992,7 @@ menu_adduid (ctrl_t ctrl, kbnode_t pub_keyblock,
return 0;
}
- err = make_keysig_packet (ctrl, &sig, pk, uid, NULL, pk, 0x13, 0, 0, 0,
+ err = make_keysig_packet (ctrl, &sig, pk, uid, NULL, pk, 0x13, 0, 0,
keygen_add_std_prefs, pk, NULL);
if (err)
{
@@ -4374,7 +4375,7 @@ menu_addrevoker (ctrl_t ctrl, kbnode_t pub_keyblock, int sensitive)
break;
}
- rc = make_keysig_packet (ctrl, &sig, pk, NULL, NULL, pk, 0x1F, 0, 0, 0,
+ rc = make_keysig_packet (ctrl, &sig, pk, NULL, NULL, pk, 0x1F, 0, 0,
keygen_add_revkey, &revkey, NULL);
if (rc)
{
@@ -5898,7 +5899,7 @@ reloop: /* (must use this, because we are modifying the list) */
}
rc = make_keysig_packet (ctrl, &sig, primary_pk,
unode->pkt->pkt.user_id,
- NULL, signerkey, 0x30, 0, 0, 0,
+ NULL, signerkey, 0x30, 0, 0,
sign_mk_attrib, &attrib, NULL);
free_public_key (signerkey);
if (rc)
@@ -5977,11 +5978,11 @@ core_revuid (ctrl_t ctrl, kbnode_t keyblock, KBNODE node,
memset (&attrib, 0, sizeof attrib);
/* should not need to cast away const here; but
revocation_reason_build_cb needs to take a non-const
- void* in order to meet the function signtuare for the
+ void* in order to meet the function signutare for the
mksubpkt argument to make_keysig_packet */
attrib.reason = (struct revocation_reason_info *)reason;
- rc = make_keysig_packet (ctrl, &sig, pk, uid, NULL, pk, 0x30, 0,
+ rc = make_keysig_packet (ctrl, &sig, pk, uid, NULL, pk, 0x30,
timestamp, 0,
sign_mk_attrib, &attrib, NULL);
if (rc)
@@ -6111,7 +6112,7 @@ menu_revkey (ctrl_t ctrl, kbnode_t pub_keyblock)
return 0;
rc = make_keysig_packet (ctrl, &sig, pk, NULL, NULL, pk,
- 0x20, 0, 0, 0,
+ 0x20, 0, 0,
revocation_reason_build_cb, reason, NULL);
if (rc)
{
@@ -6173,7 +6174,7 @@ menu_revsubkey (ctrl_t ctrl, kbnode_t pub_keyblock)
node->flag &= ~NODFLG_SELKEY;
rc = make_keysig_packet (ctrl, &sig, mainpk, NULL, subpk, mainpk,
- 0x28, 0, 0, 0, sign_mk_attrib, &attrib,
+ 0x28, 0, 0, sign_mk_attrib, &attrib,
NULL);
if (rc)
{