diff options
author | Dan Winship <danw@src.gnome.org> | 2000-02-17 00:03:14 +0800 |
---|---|---|
committer | Dan Winship <danw@src.gnome.org> | 2000-02-17 00:03:14 +0800 |
commit | 8176cca8d02c90ed2b6ec3f48f95e7209e16389b (patch) | |
tree | 1881981dd56f083d2837504f240dccd9e136a4bd /camel | |
parent | cd9e88989ff2fabdc66f96fa81e0c474e67d53aa (diff) | |
download | gsoc2013-evolution-8176cca8d02c90ed2b6ec3f48f95e7209e16389b.tar gsoc2013-evolution-8176cca8d02c90ed2b6ec3f48f95e7209e16389b.tar.gz gsoc2013-evolution-8176cca8d02c90ed2b6ec3f48f95e7209e16389b.tar.bz2 gsoc2013-evolution-8176cca8d02c90ed2b6ec3f48f95e7209e16389b.tar.lz gsoc2013-evolution-8176cca8d02c90ed2b6ec3f48f95e7209e16389b.tar.xz gsoc2013-evolution-8176cca8d02c90ed2b6ec3f48f95e7209e16389b.tar.zst gsoc2013-evolution-8176cca8d02c90ed2b6ec3f48f95e7209e16389b.zip |
Make md5_final take the MD5Context first, like md5_init and md5_update.
svn path=/trunk/; revision=1796
Diffstat (limited to 'camel')
-rw-r--r-- | camel/md5-utils.c | 8 | ||||
-rw-r--r-- | camel/md5-utils.h | 2 | ||||
-rw-r--r-- | camel/providers/MH/mh-uid.c | 2 |
3 files changed, 6 insertions, 6 deletions
diff --git a/camel/md5-utils.c b/camel/md5-utils.c index 2ebb1533f4..7363eaec40 100644 --- a/camel/md5-utils.c +++ b/camel/md5-utils.c @@ -147,7 +147,7 @@ md5_update (MD5Context *ctx, const guchar *buf, guint32 len) * copy the final md5 hash to a bufer **/ void -md5_final (guchar digest[16], MD5Context *ctx) +md5_final (MD5Context *ctx, guchar digest[16]) { guint32 count; guchar *p; @@ -313,7 +313,7 @@ md5_get_digest (const gchar *buffer, gint buffer_size, guchar digest[16]) md5_init (&ctx); md5_update (&ctx, buffer, buffer_size); - md5_final (digest, &ctx); + md5_final (&ctx, digest); } @@ -341,7 +341,7 @@ md5_get_digest_from_stream (CamelStream *stream, guchar digest[16]) nb_bytes_read = camel_stream_read (stream, tmp_buf, 1024); } - md5_final (digest, &ctx); + md5_final (&ctx, digest); } @@ -381,7 +381,7 @@ md5_get_digest_from_file (const gchar *filename, guchar digest[16]) } - md5_final (digest, &ctx); + md5_final (&ctx, digest); printf("checksum done\n"); } diff --git a/camel/md5-utils.h b/camel/md5-utils.h index a2552d21b2..e4569dd54a 100644 --- a/camel/md5-utils.h +++ b/camel/md5-utils.h @@ -48,7 +48,7 @@ void md5_get_digest_from_file (const gchar *filename, guchar digest[16]); /* raw routines */ void md5_init (MD5Context *ctx); void md5_update (MD5Context *ctx, const guchar *buf, guint32 len); -void md5_final (guchar digest[16], MD5Context *ctx); +void md5_final (MD5Context *ctx, guchar digest[16]); #endif /* MD5_UTILS_H */ diff --git a/camel/providers/MH/mh-uid.c b/camel/providers/MH/mh-uid.c index 7dbde4de00..ebcccacd23 100644 --- a/camel/providers/MH/mh-uid.c +++ b/camel/providers/MH/mh-uid.c @@ -74,7 +74,7 @@ mh_uid_get_for_file (gchar *filename, guchar uid[16]) g_array_free (header_array, TRUE); - md5_final (uid, &ctx); + md5_final (&ctx, uid); } |