summaryrefslogtreecommitdiffstats
path: root/g10/keyid.c
diff options
context:
space:
mode:
authorWerner Koch <wk@gnupg.org>2006-05-24 13:12:28 +0200
committerWerner Koch <wk@gnupg.org>2006-05-24 13:12:28 +0200
commitb61df862a7c9a8d85412b89965f5f814ab939180 (patch)
tree00a7b079e758030f618490700e3ae7b84b171776 /g10/keyid.c
parentg10/ does build again. (diff)
downloadgnupg2-b61df862a7c9a8d85412b89965f5f814ab939180.tar.xz
gnupg2-b61df862a7c9a8d85412b89965f5f814ab939180.zip
Still making gpg2 work.
At least the keyids are now correctly computed again.
Diffstat (limited to 'g10/keyid.c')
-rw-r--r--g10/keyid.c6
1 files changed, 1 insertions, 5 deletions
diff --git a/g10/keyid.c b/g10/keyid.c
index 5eb51c1f4..0012a5604 100644
--- a/g10/keyid.c
+++ b/g10/keyid.c
@@ -56,7 +56,6 @@ void
hash_public_key( gcry_md_hd_t md, PKT_public_key *pk )
{
unsigned int n = 6;
- unsigned int nb[PUBKEY_MAX_NPKEY];
unsigned int nn[PUBKEY_MAX_NPKEY];
byte *pp[PUBKEY_MAX_NPKEY];
int i;
@@ -77,7 +76,6 @@ hash_public_key( gcry_md_hd_t md, PKT_public_key *pk )
else
for(i=0; i < npkey; i++ )
{
- nb[i] = gcry_mpi_get_nbits (pk->pkey[i]);
if (gcry_mpi_print (GCRYMPI_FMT_PGP, NULL, 0, &nbytes, pk->pkey[i]))
BUG ();
pp[i] = xmalloc (nbytes);
@@ -85,7 +83,7 @@ hash_public_key( gcry_md_hd_t md, PKT_public_key *pk )
&nbytes, pk->pkey[i]))
BUG ();
nn[i] = nbytes;
- n += 2 + nn[i];
+ n += nn[i];
}
gcry_md_putc ( md, 0x99 ); /* ctb */
@@ -119,8 +117,6 @@ hash_public_key( gcry_md_hd_t md, PKT_public_key *pk )
else
for(i=0; i < npkey; i++ )
{
- gcry_md_putc ( md, nb[i]>>8);
- gcry_md_putc ( md, nb[i] );
gcry_md_write ( md, pp[i], nn[i] );
xfree(pp[i]);
}