diff options
author | Werner Koch <[email protected]> | 2000-07-14 17:34:53 +0000 |
---|---|---|
committer | Werner Koch <[email protected]> | 2000-07-14 17:34:53 +0000 |
commit | 92cd25550836198cf1e3a6aac239eef98364359d (patch) | |
tree | 4fad355126fae79c93535e0e7c6afd91e384552a /g10/encode.c | |
parent | See ChangeLog: Thu May 25 18:39:11 CEST 2000 Werner Koch (diff) | |
download | gnupg-92cd25550836198cf1e3a6aac239eef98364359d.tar.gz gnupg-92cd25550836198cf1e3a6aac239eef98364359d.zip |
See ChangeLog: Fri Jul 14 19:38:23 CEST 2000 Werner Koch
Diffstat (limited to '')
-rw-r--r-- | g10/encode.c | 9 |
1 files changed, 5 insertions, 4 deletions
diff --git a/g10/encode.c b/g10/encode.c index ed4b1df0f..6195b533c 100644 --- a/g10/encode.c +++ b/g10/encode.c @@ -1,5 +1,5 @@ /* encode.c - encode data - * Copyright (C) 1998 Free Software Foundation, Inc. + * Copyright (C) 1998, 1999, 2000 Free Software Foundation, Inc. * * This file is part of GnuPG. * @@ -41,6 +41,7 @@ static int encode_simple( const char *filename, int mode ); static int write_pubkey_enc_from_list( PK_LIST pk_list, DEK *dek, IOBUF out ); + /**************** * Emulate our old PK interface here - sometime in the future we might * change the internal design to directly fit to libgcrypt. @@ -162,7 +163,7 @@ encode_simple( const char *filename, int mode ) } if( (rc = open_outfile( filename, opt.armor? 1:0, &out )) ) { - iobuf_close(inp); + iobuf_cancel(inp); gcry_free(cfx.dek); gcry_free(s2k); return rc; @@ -510,7 +511,7 @@ write_pubkey_enc_from_list( PK_LIST pk_list, DEK *dek, IOBUF out ) * number of bits we have to use. We then encode the session * key in some way and we get it back in the big intger value * FRAME. Then we use FRAME, the public key PK->PKEY and the - * algorithm number PK->PUBKEY_ALGO and pass it to pk_encrypt + * algorithm number PK->PUBKEY_ALGO and pass it to pubkey_encrypt * which returns the encrypted value in the array ENC->DATA. * This array has a size which depends on the used algorithm * (e.g. 2 for ElGamal). We don't need frame anymore because we @@ -525,7 +526,7 @@ write_pubkey_enc_from_list( PK_LIST pk_list, DEK *dek, IOBUF out ) log_error("pubkey_encrypt failed: %s\n", gpg_errstr(rc) ); else { if( opt.verbose ) { - char *ustr = get_user_id_string( enc->keyid ); + char *ustr = get_user_id_string_native( enc->keyid ); log_info(_("%s/%s encrypted for: %s\n"), gcry_pk_algo_name(enc->pubkey_algo), gcry_cipher_algo_name(dek->algo), ustr ); |