Mercurial > hg > octave-nkf > gnulib-hg
changeset 6362:2bcfc491052b
* gc-libgcrypt.c (gc_md5): Fix assert call.
(gc_md5): Fix typo.
* gc.h (gc_hash_buffer): Use gc_hash in prototype.
* gc-libgcrypt.c (gc_hash_buffer): Ditto.
* gc-gnulib.c (gc_hash_buffer): Ditto.
author | Simon Josefsson <simon@josefsson.org> |
---|---|
date | Wed, 12 Oct 2005 00:23:38 +0000 |
parents | e5493443881a |
children | bae11f33bf3c |
files | lib/ChangeLog lib/gc-gnulib.c lib/gc-libgcrypt.c lib/gc.h |
diffstat | 4 files changed, 16 insertions(+), 5 deletions(-) [+] |
line wrap: on
line diff
--- a/lib/ChangeLog +++ b/lib/ChangeLog @@ -1,3 +1,14 @@ +2005-10-12 Simon Josefsson <jas@extundo.com> + + * gc-libgcrypt.c (gc_md5): Fix assert call. + (gc_md5): Fix typo. + + * gc.h (gc_hash_buffer): Use gc_hash in prototype. + + * gc-libgcrypt.c (gc_hash_buffer): Ditto. + + * gc-gnulib.c (gc_hash_buffer): Ditto. + 2005-10-11 Bruno Haible <bruno@clisp.org> * c-strcasestr.h: New file, from GNU gettext.
--- a/lib/gc-gnulib.c +++ b/lib/gc-gnulib.c @@ -138,7 +138,7 @@ /* Hashes. */ int -gc_hash_buffer (int hash, const void *in, size_t inlen, char *resbuf) +gc_hash_buffer (Gc_hash hash, const void *in, size_t inlen, char *resbuf) { switch (hash) {
--- a/lib/gc-libgcrypt.c +++ b/lib/gc-libgcrypt.c @@ -97,7 +97,7 @@ /* Hashes. */ int -gc_hash_buffer (int hash, const void *in, size_t inlen, char *resbuf) +gc_hash_buffer (Gc_hash hash, const void *in, size_t inlen, char *resbuf) { int gcryalg; @@ -126,7 +126,7 @@ gpg_error_t err; unsigned char *p; - assert (outlen == 16); + assert (outlen == GC_MD5_DIGEST_SIZE); err = gcry_md_open (&hd, GCRY_MD_MD5, 0); if (err != GPG_ERR_NO_ERROR) @@ -137,7 +137,7 @@ p = gcry_md_read (hd, GCRY_MD_MD5); if (p == NULL) { - gcry_md_close (mdh); + gcry_md_close (hd); return GC_INVALID_HASH; }
--- a/lib/gc.h +++ b/lib/gc.h @@ -71,7 +71,7 @@ must be 16 bytes. The return value is 0 (GC_OK) on success, or another Gc_rc error code. */ extern int -gc_hash_buffer (int hash, const void *in, size_t inlen, char *out); +gc_hash_buffer (Gc_hash hash, const void *in, size_t inlen, char *out); /* One-call interface. */ extern int gc_md5 (const void *in, size_t inlen, void *resbuf);